diff --git a/debian/README.source b/debian/README.source deleted file mode 100644 index cff05f9..0000000 --- a/debian/README.source +++ /dev/null @@ -1,6 +0,0 @@ -Building virt-viewer for Debian -------------------------------- - -The virt-viewer source package uses quilt to apply and remove its patches. -Please refer to /usr/share/doc/quilt/README.source for information about how to -use quilt for source packages. diff --git a/debian/control b/debian/control index a8ea9a1..7e7675c 100644 --- a/debian/control +++ b/debian/control @@ -10,11 +10,8 @@ libgtk-vnc-1.0-dev (>= 0.3.4), libxml2-dev, libgtk2.0-dev (>= 2.10), - xulrunner-dev, autotools-dev, - quilt, automake, - autoconf, libffi-dev, libtool, libglade2-dev, @@ -36,20 +33,3 @@ console The viewer can connect to remote hosts to lookup the console information and then also connect to the remote console using the same network transport. - -Package: mozilla-virt-viewer -Architecture: any -Section: web -Depends: ${shlibs:Depends}, ${misc:Depends}, virt-viewer (= ${binary:Version}), - iceweasel | iceape-browser -Description: A virt-viewer widget for GTK+ (mozilla plugin) - The console is accessed using the VNC protocol. The guest can be referred to - based on its name, ID, or UUID. If the guest is not already running, then the - viewer can be told to wait until is starts before attempting to connect to the - console The viewer can connect to remote hosts to lookup the console - information and then also connect to the remote console using the same network - transport. - . - This package contains the experimental mozilla plugin. The plugin is not - secure. Plase check the README. - diff --git a/debian/mozilla-virt-viewer.examples b/debian/mozilla-virt-viewer.examples deleted file mode 100644 index e9986cd..0000000 --- a/debian/mozilla-virt-viewer.examples +++ /dev/null @@ -1 +0,0 @@ -plugin/test.html diff --git a/debian/mozilla-virt-viewer.install b/debian/mozilla-virt-viewer.install deleted file mode 100644 index d0b493a..0000000 --- a/debian/mozilla-virt-viewer.install +++ /dev/null @@ -1 +0,0 @@ -usr/lib/mozilla/plugins/*.so usr/lib/virt-viewer/plugins/ diff --git a/debian/mozilla-virt-viewer.links b/debian/mozilla-virt-viewer.links deleted file mode 100644 index 6666974..0000000 --- a/debian/mozilla-virt-viewer.links +++ /dev/null @@ -1,2 +0,0 @@ -/usr/lib/virt-viewer/plugins/virt-viewer-plugin.so /usr/lib/iceweasel/plugins/virt-viewer-plugin.so -/usr/lib/virt-viewer/plugins/virt-viewer-plugin.so /usr/lib/iceape/plugins/virt-viewer-plugin.so diff --git a/debian/patches/0001-Fix-build-with-xulrunner-1.9.1.patch b/debian/patches/0001-Fix-build-with-xulrunner-1.9.1.patch deleted file mode 100644 index 2ac1e47..0000000 --- a/debian/patches/0001-Fix-build-with-xulrunner-1.9.1.patch +++ /dev/null @@ -1,272 +0,0 @@ -From: =?UTF-8?q?Guido=20G=C3=BCnther?= -Date: Tue, 2 Feb 2010 20:16:52 +0100 -Subject: Fix build with xulrunner 1.9.1 - ---- - plugin/npshell.c | 1 - - plugin/npunix.c | 176 +++++++++++++++++++++++++++++++++++++++++++++++++++--- - 2 files changed, 168 insertions(+), 9 deletions(-) - -diff --git a/plugin/npshell.c b/plugin/npshell.c -index ccd11a5..c369cf8 100644 ---- a/plugin/npshell.c -+++ b/plugin/npshell.c -@@ -84,7 +84,6 @@ Contributor(s): Adobe Systems Incorporated. - #include - - #include --#include - - #include "virt-viewer-plugin.h" - -diff --git a/plugin/npunix.c b/plugin/npunix.c -index ddc4bdf..e17e942 100644 ---- a/plugin/npunix.c -+++ b/plugin/npunix.c -@@ -57,7 +57,151 @@ - - #include - #include -+#if (((NP_VERSION_MAJOR << 8) + NP_VERSION_MINOR) < 20) - #include -+#else -+#include -+// For 1.9 compatibility -+// ------------------------------------------------ -+typedef NPError (*NPN_GetValueUPP)(NPP instance, NPNVariable variable, void *ret_alue); -+#define NewNPN_GetValueProc(FUNC) \ -+ ((NPN_GetValueUPP) (FUNC)) -+#define CallNPN_GetValueProc(FUNC, ARG1, ARG2, ARG3) \ -+ (*(FUNC))((ARG1), (ARG2), (ARG3)) -+ -+typedef NPError (*NPN_SetValueUPP)(NPP instance, NPPVariable variable, void *ret_alue); -+#define NewNPN_SetValueProc(FUNC) \ -+ ((NPN_SetValueUPP) (FUNC)) -+#define CallNPN_SetValueProc(FUNC, ARG1, ARG2, ARG3) \ -+ (*(FUNC))((ARG1), (ARG2), (ARG3)) -+ -+typedef NPError (*NPN_GetURLUPP)(NPP instance, const char* url, const char* window); -+#define NewNPN_GetURLProc(FUNC) \ -+ ((NPN_GetURLUPP) (FUNC)) -+#define CallNPN_GetURLProc(FUNC, ARG1, ARG2, ARG3) \ -+ (*(FUNC))((ARG1), (ARG2), (ARG3)) -+ -+typedef NPError (*NPN_GetURLNotifyUPP)(NPP instance, const char* url, const char* window, void* notifyData); -+#define NewNPN_GetURLNotifyProc(FUNC) \ -+ ((NPN_GetURLNotifyUPP) (FUNC)) -+#define CallNPN_GetURLNotifyProc(FUNC, ARG1, ARG2, ARG3, ARG4) \ -+ (*(FUNC))((ARG1), (ARG2), (ARG3), (ARG4)) -+ -+typedef NPError (*NPN_PostURLUPP)(NPP instance, const char* url, const char* window, uint32_t len, const char* buf, NPBool file); -+#define NewNPN_PostURLProc(FUNC) \ -+ ((NPN_PostURLUPP) (FUNC)) -+#define CallNPN_PostURLProc(FUNC, ARG1, ARG2, ARG3, ARG4, ARG5, ARG6) \ -+ (*(FUNC))((ARG1), (ARG2), (ARG3), (ARG4), (ARG5), (ARG6)) -+ -+typedef NPError (*NPN_PostURLNotifyUPP)(NPP instance, const char* url, const char* window, uint32_t len, const char* buf, NPBool file, void* notifyData); -+#define NewNPN_PostURLNotifyProc(FUNC) \ -+ ((NPN_PostURLNotifyUPP) (FUNC)) -+#define CallNPN_PostURLNotifyProc(FUNC, ARG1, ARG2, ARG3, ARG4, ARG5, ARG6, ARG7) \ -+ (*(FUNC))((ARG1), (ARG2), (ARG3), (ARG4), (ARG5), (ARG6), (ARG7)) -+ -+typedef NPError (*NPN_RequestReadUPP)(NPStream* stream, NPByteRange* rangeList); -+#define NewNPN_RequestReadProc(FUNC) \ -+ ((NPN_RequestReadUPP) (FUNC)) -+#define CallNPN_RequestReadProc(FUNC, stream, range) \ -+ (*(FUNC))((stream), (range)) -+ -+typedef NPError (*NPN_NewStreamUPP)(NPP instance, NPMIMEType type, const char* window, NPStream** stream); -+#define NewNPN_NewStreamProc(FUNC) \ -+ ((NPN_NewStreamUPP) (FUNC)) -+#define CallNPN_NewStreamProc(FUNC, npp, type, window, stream) \ -+ (*(FUNC))((npp), (type), (window), (stream)) -+ -+typedef int32_t (*NPN_WriteUPP)(NPP instance, NPStream* stream, int32_t len, void* buffer); -+#define NewNPN_WriteProc(FUNC) \ -+ ((NPN_WriteUPP) (FUNC)) -+#define CallNPN_WriteProc(FUNC, npp, stream, len, buffer) \ -+ (*(FUNC))((npp), (stream), (len), (buffer)) -+ -+typedef NPError (*NPN_DestroyStreamUPP)(NPP instance, NPStream* stream, NPReason reason); -+#define NewNPN_DestroyStreamProc(FUNC) \ -+ ((NPN_DestroyStreamUPP) (FUNC)) -+#define CallNPN_DestroyStreamProc(FUNC, npp, stream, reason) \ -+ (*(FUNC))((npp), (stream), (reason)) -+ -+typedef void (*NPN_StatusUPP)(NPP instance, const char* message); -+#define NewNPN_StatusProc(FUNC) \ -+ ((NPN_StatusUPP) (FUNC)) -+#define CallNPN_StatusProc(FUNC, npp, msg) \ -+ (*(FUNC))((npp), (msg)) -+ -+typedef const char* (*NPN_UserAgentUPP)(NPP instance); -+#define NewNPN_UserAgentProc(FUNC) \ -+ ((NPN_UserAgentUPP) (FUNC)) -+#define CallNPN_UserAgentProc(FUNC, ARG1) \ -+ (*(FUNC))((ARG1)) -+ -+typedef void* (*NPN_MemAllocUPP)(uint32_t size); -+#define NewNPN_MemAllocProc(FUNC) \ -+ ((NPN_MemAllocUPP) (FUNC)) -+#define CallNPN_MemAllocProc(FUNC, ARG1) \ -+ (*(FUNC))((ARG1)) -+ -+typedef void (*NPN_MemFreeUPP)(void* ptr); -+#define NewNPN_MemFreeProc(FUNC) \ -+ ((NPN_MemFreeUPP) (FUNC)) -+#define CallNPN_MemFreeProc(FUNC, ARG1) \ -+ (*(FUNC))((ARG1)) -+ -+typedef uint32_t (*NPN_MemFlushUPP)(uint32_t size); -+#define NewNPN_MemFlushProc(FUNC) \ -+ ((NPN_MemFlushUPP) (FUNC)) -+#define CallNPN_MemFlushProc(FUNC, ARG1) \ -+ (*(FUNC))((ARG1)) -+ -+typedef void (*NPN_ReloadPluginsUPP)(NPBool reloadPages); -+#define NewNPN_ReloadPluginsProc(FUNC) \ -+ ((NPN_ReloadPluginsUPP) (FUNC)) -+#define CallNPN_ReloadPluginsProc(FUNC, ARG1) \ -+ (*(FUNC))((ARG1)) -+ -+typedef void (*NPN_InvalidateRectUPP)(NPP instance, NPRect *rect); -+#define NewNPN_InvalidateRectProc(FUNC) \ -+ ((NPN_InvalidateRectUPP) (FUNC)) -+#define CallNPN_InvalidateRectProc(FUNC, ARG1, ARG2) \ -+ (*(FUNC))((ARG1), (ARG2)) -+ -+typedef void (*NPN_InvalidateRegionUPP)(NPP instance, NPRegion region); -+#define NewNPN_InvalidateRegionProc(FUNC) \ -+ ((NPN_InvalidateRegionUPP) (FUNC)) -+#define CallNPN_InvalidateRegionProc(FUNC, ARG1, ARG2) \ -+ (*(FUNC))((ARG1), (ARG2)) -+ -+typedef void (*NPN_ForceRedrawUPP)(NPP instance); -+#define NewNPN_ForceRedrawProc(FUNC) \ -+ ((NPN_ForceRedrawUPP) (FUNC)) -+#define CallNPN_ForceRedrawProc(FUNC, ARG1) \ -+ (*(FUNC))((ARG1)) -+ -+typedef void* (*NPN_GetJavaEnvUPP)(); -+#define NewNPN_GetJavaEnvProc(FUNC) \ -+ ((NPN_GetJavaEnvUPP) (FUNC)) -+#define CallNPN_GetJavaEnvProc(FUNC) \ -+ (*(FUNC))() -+ -+typedef void* (*NPN_GetJavaPeerUPP)(NPP instance); -+#define NewNPN_GetJavaPeerProc(FUNC) \ -+ ((NPN_GetJavaPeerUPP) (FUNC)) -+#define CallNPN_GetJavaPeerProc(FUNC, ARG1) \ -+ (*(FUNC))((ARG1)) -+ -+typedef bool (*NPN_PushPopupsEnabledStateUPP)(NPP instance, NPBool enabled); -+#define NewNPN_PushPopupsEnabledStateProc(FUNC) \ -+ ((NPN_PushPopupsEnabledStateUPP) (FUNC)) -+#define CallNPN_PushPopupsEnabledStateProc(FUNC, ARG1, ARG2) \ -+ (*(FUNC))((ARG1), (ARG2)) -+ -+typedef bool (*NPN_PopPopupsEnabledStateUPP)(NPP instance); -+#define NewNPN_PopPopupsEnabledStateProc(FUNC) \ -+ ((NPN_PopPopupsEnabledStateUPP) (FUNC)) -+#define CallNPN_PopPopupsEnabledStateProc(FUNC, ARG1) \ -+ (*(FUNC))((ARG1)) -+ -+#endif - - #include /* just for G_GNUC_UNUSED */ - -@@ -134,14 +278,14 @@ NPN_GetURLNotify(NPP instance, const char* url, const char* window, void* notify - - NPError - NPN_PostURL(NPP instance, const char* url, const char* window, -- uint32 len, const char* buf, NPBool file) -+ uint32_t len, const char* buf, NPBool file) - { - return CallNPN_PostURLProc(gNetscapeFuncs.posturl, instance, - url, window, len, buf, file); - } - - NPError --NPN_PostURLNotify(NPP instance, const char* url, const char* window, uint32 len, -+NPN_PostURLNotify(NPP instance, const char* url, const char* window, uint32_t len, - const char* buf, NPBool file, void* notifyData) - { - return CallNPN_PostURLNotifyProc(gNetscapeFuncs.posturlnotify, -@@ -164,7 +308,7 @@ NPN_NewStream(NPP instance, NPMIMEType type, const char *window, - } - - int32 --NPN_Write(NPP instance, NPStream* stream, int32 len, void* buffer) -+NPN_Write(NPP instance, NPStream* stream, int32_t len, void* buffer) - { - return CallNPN_WriteProc(gNetscapeFuncs.write, instance, - stream, len, buffer); -@@ -190,7 +334,7 @@ NPN_UserAgent(NPP instance) - } - - void* --NPN_MemAlloc(uint32 size) -+NPN_MemAlloc(uint32_t size) - { - return CallNPN_MemAllocProc(gNetscapeFuncs.memalloc, size); - } -@@ -200,7 +344,7 @@ void NPN_MemFree(void* ptr) - CallNPN_MemFreeProc(gNetscapeFuncs.memfree, ptr); - } - --uint32 NPN_MemFlush(uint32 size) -+uint32_t NPN_MemFlush(uint32_t size) - { - return CallNPN_MemFlushProc(gNetscapeFuncs.memflush, size); - } -@@ -269,8 +413,8 @@ void NPN_PopPopupsEnabledState(NPP instance) - ***********************************************************************/ - - static NPError --Private_New(NPMIMEType pluginType, NPP instance, uint16 mode, -- int16 argc, char* argn[], char* argv[], NPSavedData* saved) -+Private_New(NPMIMEType pluginType, NPP instance, uint16_t mode, -+ int16_t argc, char* argn[], char* argv[], NPSavedData* saved) - { - NPError ret; - PLUGINDEBUGSTR("New"); -@@ -315,7 +459,7 @@ Private_WriteReady(NPP instance, NPStream* stream) - } - - static int32 --Private_Write(NPP instance, NPStream* stream, int32 offset, int32 len, -+Private_Write(NPP instance, NPStream* stream, int32_t offset, int32_t len, - void* buffer) - { - unsigned int result; -@@ -501,6 +645,7 @@ NP_Initialize(NPNetscapeFuncs* nsTable, NPPluginFuncs* pluginFuncs) - */ - pluginFuncs->version = (NP_VERSION_MAJOR << 8) + NP_VERSION_MINOR; - pluginFuncs->size = sizeof(NPPluginFuncs); -+#if (((NP_VERSION_MAJOR << 8) + NP_VERSION_MINOR) < 20) - pluginFuncs->newp = NewNPP_NewProc(Private_New); - pluginFuncs->destroy = NewNPP_DestroyProc(Private_Destroy); - pluginFuncs->setwindow = NewNPP_SetWindowProc(Private_SetWindow); -@@ -513,6 +658,21 @@ NP_Initialize(NPNetscapeFuncs* nsTable, NPPluginFuncs* pluginFuncs) - pluginFuncs->urlnotify = NewNPP_URLNotifyProc(Private_URLNotify); - pluginFuncs->getvalue = NewNPP_GetValueProc(Private_GetValue); - pluginFuncs->event = NewNPP_HandleEventProc(Private_HandleEvent); -+#else -+ pluginFuncs->newp = (NPP_NewProcPtr)(Private_New); -+ pluginFuncs->destroy = (NPP_DestroyProcPtr)(Private_Destroy); -+ pluginFuncs->setwindow = (NPP_SetWindowProcPtr)(Private_SetWindow); -+ pluginFuncs->newstream = (NPP_NewStreamProcPtr)(Private_NewStream); -+ pluginFuncs->destroystream = (NPP_DestroyStreamProcPtr)(Private_DestroyStream); -+ pluginFuncs->asfile = (NPP_StreamAsFileProcPtr)(Private_StreamAsFile); -+ pluginFuncs->writeready = (NPP_WriteReadyProcPtr)(Private_WriteReady); -+ pluginFuncs->write = (NPP_WriteProcPtr)(Private_Write); -+ pluginFuncs->print = (NPP_PrintProcPtr)(Private_Print); -+ pluginFuncs->urlnotify = (NPP_URLNotifyProcPtr)(Private_URLNotify); -+ pluginFuncs->getvalue = (NPP_GetValueProcPtr)(Private_GetValue); -+ pluginFuncs->event = (NPP_HandleEventProcPtr)(Private_HandleEvent); -+#endif -+ - #ifdef OJI - pluginFuncs->javaClass = Private_GetJavaClass(); - #endif --- diff --git a/debian/patches/0002-Define-GLADE_DIR.patch b/debian/patches/0002-Define-GLADE_DIR.patch deleted file mode 100644 index 3c46937..0000000 --- a/debian/patches/0002-Define-GLADE_DIR.patch +++ /dev/null @@ -1,23 +0,0 @@ -From: =?UTF-8?q?Guido=20G=C3=BCnther?= -Date: Tue, 2 Feb 2010 20:44:38 +0100 -Subject: Define GLADE_DIR - -so the plugin can find the glade files. ---- - plugin/Makefile.am | 2 ++ - 1 files changed, 2 insertions(+), 0 deletions(-) - -diff --git a/plugin/Makefile.am b/plugin/Makefile.am -index 93284cc..dde76a9 100644 ---- a/plugin/Makefile.am -+++ b/plugin/Makefile.am -@@ -3,6 +3,8 @@ if ENABLE_PLUGIN - plugindir = $(libdir)/mozilla/plugins - plugin_LTLIBRARIES = virt-viewer-plugin.la - -+gladedir = $(pkgdatadir)/ui -+ - virt_viewer_plugin_la_SOURCES = \ - ../src/util.c ../src/util.h \ - ../src/auth.c ../src/auth.h \ --- diff --git a/debian/patches/0003-Add-some-docs.patch b/debian/patches/0003-Add-some-docs.patch deleted file mode 100644 index 4fcc731..0000000 --- a/debian/patches/0003-Add-some-docs.patch +++ /dev/null @@ -1,81 +0,0 @@ -From: =?UTF-8?q?Guido=20G=C3=BCnther?= -Date: Tue, 2 Feb 2010 20:59:10 +0100 -Subject: Add some docs - ---- - plugin/README | 40 ++++++++++++++++++++++++++++++++++++++++ - plugin/test.html | 17 +++++++++++++++++ - 2 files changed, 57 insertions(+), 0 deletions(-) - create mode 100644 plugin/README - create mode 100644 plugin/test.html - -diff --git a/plugin/README b/plugin/README -new file mode 100644 -index 0000000..dea7b78 ---- /dev/null -+++ b/plugin/README -@@ -0,0 +1,40 @@ -+Testing -+------- -+ -+Restart your browser. In the location bar, type: -+ -+ about:plugins -+ -+Amongst your other plugins you should see the virt-viewer plugin: -+ -+ Virt-viewer browser plugin -+ -+ File name: virt-viewer-plugin.so -+ Virtual machine console viewer plugin -+ -+ MIME Type Description Suffixes Enabled -+ application/x-virt-viewer Virt viewer virt-viewer Yes -+ -+If that appears, then next edit the test.html page in the current -+directory. You will need to change the name of this page to point -+to a virtual machine. -+ -+Then load the edited 'test.html' page into your browser, and you should see a -+virt-viewer widget and the display of the virtual machine. -+ -+SECURITY -+-------- -+ -+If you install this plugin, then any web page could invoke it. -+ -+Specific security implications of this are: -+ -+(1) Malicious web page could cause your browser to connect to an arbitrary -+virtual machine even addresses behind a firewall. If you allow the plugin to be -+controlled by Javascript, and to communicate back success/failure indications, -+then this would allow a hacker to probe ports which they might otherwise not -+have access to. -+ -+(2) A web page could connect to a malicious virtual machine. The virt-viewer -+widget is not hardened against responses from malicious VNC servers which might -+provide faulty responses, causing virt-viewer to crash or be subverted. -diff --git a/plugin/test.html b/plugin/test.html -new file mode 100644 -index 0000000..33d333f ---- /dev/null -+++ b/plugin/test.html -@@ -0,0 +1,17 @@ -+ -+ -+ -+

Virt-viewer applet test

-+ -+

You will need to edit the source to -+ set uri, name etc.

-+ -+ -+ -+ -+

End of page

-+ -+ -+ --- diff --git a/debian/patches/series b/debian/patches/series deleted file mode 100644 index 3d290b1..0000000 --- a/debian/patches/series +++ /dev/null @@ -1,3 +0,0 @@ -0001-Fix-build-with-xulrunner-1.9.1.patch -0002-Define-GLADE_DIR.patch -0003-Add-some-docs.patch diff --git a/debian/rules b/debian/rules index 64b14b0..dadbd40 100755 --- a/debian/rules +++ b/debian/rules @@ -1,23 +1,6 @@ #!/usr/bin/make -f LDFLAGS += "-Wl,--as-needed" - + include /usr/share/cdbs/1/rules/debhelper.mk include /usr/share/cdbs/1/class/autotools.mk -include /usr/share/cdbs/1/rules/patchsys-quilt.mk - -DEB_CONFIGURE_EXTRA_FLAGS += --enable-plugin=yes -DEB_DH_MAKESHLIBS_ARGS_mozilla-virt-viewer += --noscripts -X /plugins/ - -clean:: - rm -f $(CURDIR)/aclocal.m4 - rm -f $(CURDIR)/config.h.in - rm -f $(CURDIR)/configure - rm -f $(CURDIR)/Makefile.in - rm -f $(CURDIR)/man/Makefile.in - rm -f $(CURDIR)/man/virt-viewer.1 - rm -f $(CURDIR)/plugin/Makefile.in - rm -f $(CURDIR)/src/Makefile.in - -post-patches:: - autoreconf -i diff --git a/debian/virt-viewer.install b/debian/virt-viewer.install deleted file mode 100644 index 644b714..0000000 --- a/debian/virt-viewer.install +++ /dev/null @@ -1,3 +0,0 @@ -usr/bin/ -usr/share/man/ -usr/share/virt-viewer/