summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--exip/common.h24
-rw-r--r--exip/exip.dsp133
-rw-r--r--exip/exip.dsw29
-rw-r--r--exip/exip.plg64
-rw-r--r--exip/getip.cpp52
-rw-r--r--exip/getip.h4
-rw-r--r--exip/main.cpp161
-rw-r--r--exip/options.cpp62
-rw-r--r--exip/options.h19
-rw-r--r--exip/resource.h18
-rw-r--r--exip/resource.rc96
11 files changed, 662 insertions, 0 deletions
diff --git a/exip/common.h b/exip/common.h
new file mode 100644
index 0000000..6335ee6
--- /dev/null
+++ b/exip/common.h
@@ -0,0 +1,24 @@
+#ifndef _COMMON_H
+#define _COMMON_H
+
+#define MODULE "ExIP"
+
+#include <windows.h>
+#include <stdio.h>
+
+#include "../../include/newpluginapi.h"
+#include "../../include/m_options.h"
+#include "../../include/m_langpack.h"
+#include "../../include/m_system.h"
+#include "../../include/m_netlib.h"
+#include "../../include/m_database.h"
+
+#include "../../include/m_clui.h"
+
+extern HANDLE hNetlibUser;
+extern HINSTANCE hInst;
+extern PLUGINLINK *pluginLink;
+
+extern HANDLE mainThread;
+
+#endif
diff --git a/exip/exip.dsp b/exip/exip.dsp
new file mode 100644
index 0000000..fab726f
--- /dev/null
+++ b/exip/exip.dsp
@@ -0,0 +1,133 @@
+# Microsoft Developer Studio Project File - Name="exip" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 6.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
+
+CFG=exip - Win32 Debug
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE use the Export Makefile command and run
+!MESSAGE
+!MESSAGE NMAKE /f "exip.mak".
+!MESSAGE
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE
+!MESSAGE NMAKE /f "exip.mak" CFG="exip - Win32 Debug"
+!MESSAGE
+!MESSAGE Possible choices for configuration are:
+!MESSAGE
+!MESSAGE "exip - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE "exip - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE
+
+# Begin Project
+# PROP AllowPerConfigDependencies 0
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+CPP=cl.exe
+MTL=midl.exe
+RSC=rc.exe
+
+!IF "$(CFG)" == "exip - Win32 Release"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "Release"
+# PROP BASE Intermediate_Dir "Release"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "Release"
+# PROP Intermediate_Dir "Release"
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "EXIP_EXPORTS" /YX /FD /c
+# ADD CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "EXIP_EXPORTS" /YX /FD /c
+# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
+# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
+# ADD BASE RSC /l 0xc09 /d "NDEBUG"
+# ADD RSC /l 0xc09 /d "NDEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LINK32=link.exe
+# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
+# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
+
+!ELSEIF "$(CFG)" == "exip - Win32 Debug"
+
+# PROP BASE Use_MFC 0
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "Debug"
+# PROP BASE Intermediate_Dir "Debug"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 0
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "Debug"
+# PROP Intermediate_Dir "Debug"
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "EXIP_EXPORTS" /YX /FD /GZ /c
+# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "EXIP_EXPORTS" /YX /FD /GZ /c
+# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
+# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
+# ADD BASE RSC /l 0xc09 /d "_DEBUG"
+# ADD RSC /l 0xc09 /d "_DEBUG"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LINK32=link.exe
+# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
+# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
+
+!ENDIF
+
+# Begin Target
+
+# Name "exip - Win32 Release"
+# Name "exip - Win32 Debug"
+# Begin Group "Source Files"
+
+# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
+# Begin Source File
+
+SOURCE=.\getip.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\main.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\options.cpp
+# End Source File
+# End Group
+# Begin Group "Header Files"
+
+# PROP Default_Filter "h;hpp;hxx;hm;inl"
+# Begin Source File
+
+SOURCE=.\common.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\getip.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\options.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\resource.h
+# End Source File
+# End Group
+# Begin Group "Resource Files"
+
+# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
+# Begin Source File
+
+SOURCE=.\resource.rc
+# End Source File
+# End Group
+# End Target
+# End Project
diff --git a/exip/exip.dsw b/exip/exip.dsw
new file mode 100644
index 0000000..c5dbfc1
--- /dev/null
+++ b/exip/exip.dsw
@@ -0,0 +1,29 @@
+Microsoft Developer Studio Workspace File, Format Version 6.00
+# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
+
+###############################################################################
+
+Project: "exip"=".\exip.dsp" - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+}}}
+
+###############################################################################
+
+Global:
+
+Package=<5>
+{{{
+}}}
+
+Package=<3>
+{{{
+}}}
+
+###############################################################################
+
diff --git a/exip/exip.plg b/exip/exip.plg
new file mode 100644
index 0000000..47048d8
--- /dev/null
+++ b/exip/exip.plg
@@ -0,0 +1,64 @@
+<html>
+<body>
+<pre>
+<h1>Build Log</h1>
+<h3>
+--------------------Configuration: exip - Win32 Release--------------------
+</h3>
+<h3>Command Lines</h3>
+Creating temporary file "C:\DOCUME~1\sje\LOCALS~1\Temp\RSPB0.tmp" with contents
+[
+/nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "EXIP_EXPORTS" /Fp"Release/exip.pch" /YX /Fo"Release/" /Fd"Release/" /FD /c
+"C:\Documents and Settings\sje\My Documents\MyProjects\miranda\plugins\exip\main.cpp"
+]
+Creating command line "cl.exe @C:\DOCUME~1\sje\LOCALS~1\Temp\RSPB0.tmp"
+Creating temporary file "C:\DOCUME~1\sje\LOCALS~1\Temp\RSPB1.tmp" with contents
+[
+kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /incremental:no /pdb:"Release/exip.pdb" /machine:I386 /out:"Release/exip.dll" /implib:"Release/exip.lib"
+".\Release\getip.obj"
+".\Release\main.obj"
+".\Release\options.obj"
+".\Release\resource.res"
+]
+Creating command line "link.exe @C:\DOCUME~1\sje\LOCALS~1\Temp\RSPB1.tmp"
+<h3>Output Window</h3>
+Compiling...
+main.cpp
+Linking...
+ Creating library Release/exip.lib and object Release/exip.exp
+
+
+
+<h3>Results</h3>
+exip.dll - 0 error(s), 0 warning(s)
+<h3>
+--------------------Configuration: exip - Win32 Debug--------------------
+</h3>
+<h3>Command Lines</h3>
+Creating temporary file "C:\DOCUME~1\sje\LOCALS~1\Temp\RSPB5.tmp" with contents
+[
+/nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "EXIP_EXPORTS" /Fp"Debug/exip.pch" /YX /Fo"Debug/" /Fd"Debug/" /FD /GZ /c
+"C:\Documents and Settings\sje\My Documents\MyProjects\miranda\plugins\exip\main.cpp"
+]
+Creating command line "cl.exe @C:\DOCUME~1\sje\LOCALS~1\Temp\RSPB5.tmp"
+Creating temporary file "C:\DOCUME~1\sje\LOCALS~1\Temp\RSPB6.tmp" with contents
+[
+kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /incremental:yes /pdb:"Debug/exip.pdb" /debug /machine:I386 /out:"Debug/exip.dll" /implib:"Debug/exip.lib" /pdbtype:sept
+".\Debug\getip.obj"
+".\Debug\main.obj"
+".\Debug\options.obj"
+".\Debug\resource.res"
+]
+Creating command line "link.exe @C:\DOCUME~1\sje\LOCALS~1\Temp\RSPB6.tmp"
+<h3>Output Window</h3>
+Compiling...
+main.cpp
+Linking...
+
+
+
+<h3>Results</h3>
+exip.dll - 0 error(s), 0 warning(s)
+</pre>
+</body>
+</html>
diff --git a/exip/getip.cpp b/exip/getip.cpp
new file mode 100644
index 0000000..4c299e6
--- /dev/null
+++ b/exip/getip.cpp
@@ -0,0 +1,52 @@
+#include "getip.h"
+
+const char* data_prefix = "Current IP Address: ";
+const int data_prefix_len = 20;
+
+bool RetreiveIP() {
+ NETLIBHTTPREQUEST *resp = 0;
+ NETLIBHTTPREQUEST req = {0};
+
+ req.cbSize = sizeof(req);
+ req.requestType = REQUEST_GET;
+ req.szUrl = "http://checkip.dyndns.org";
+ req.flags = NLHRF_DUMPASTEXT;
+
+ resp = (NETLIBHTTPREQUEST *)CallService(MS_NETLIB_HTTPTRANSACTION, (WPARAM)hNetlibUser, (LPARAM)&req);
+
+ if(!resp) {
+ DBWriteContactSettingString(0, MODULE, "ExternalIP", Translate("Unknown"));
+ return false;
+ }
+
+ if(resp->resultCode != 200) {
+ DBWriteContactSettingString(0, MODULE, "ExternalIP", Translate("Unknown"));
+ return false;
+ }
+
+ int i1 = 0, i2 = 0;
+ char *ip = 0;
+ while(i1 < resp->dataLength) {
+ while(i1 + i2 < resp->dataLength && resp->pData[i1 + i2] == data_prefix[i2] && i2 < data_prefix_len) i2++;
+ if(i2 == data_prefix_len) {
+ // found prefix
+ i1 += i2;
+ ip = &resp->pData[i1];
+
+ i2 = 0;
+ while(resp->pData[i1 + i2] != '<' && i1 + i2 < resp->dataLength) i2++;
+ if(resp->pData[i1 + i2] == '<') resp->pData[i1 + i2] = 0;
+
+ // ip now points to ip address
+ DBWriteContactSettingString(0, MODULE, "ExternalIP", ip);
+ break;
+ }
+ i1++;
+ }
+
+ if(!ip) DBWriteContactSettingString(0, MODULE, "ExternalIP", Translate("Unknown"));
+
+ CallService(MS_NETLIB_FREEHTTPREQUESTSTRUCT, 0, (LPARAM)resp);
+
+ return true;
+} \ No newline at end of file
diff --git a/exip/getip.h b/exip/getip.h
new file mode 100644
index 0000000..782d1fa
--- /dev/null
+++ b/exip/getip.h
@@ -0,0 +1,4 @@
+#include "common.h"
+
+bool RetreiveIP();
+
diff --git a/exip/main.cpp b/exip/main.cpp
new file mode 100644
index 0000000..a7753e1
--- /dev/null
+++ b/exip/main.cpp
@@ -0,0 +1,161 @@
+#include "common.h"
+#include "options.h"
+#include "getip.h"
+
+HINSTANCE hInst;
+PLUGINLINK *pluginLink;
+
+HANDLE hNetlibUser = 0;
+HANDLE mainThread;
+
+// plugin stuff
+PLUGININFO pluginInfo={
+ sizeof(PLUGININFO),
+ "ExIP",
+ PLUGIN_MAKE_VERSION(0, 0, 0, 1),
+ "Retreive external IP address",
+ "Scott Ellis",
+ "mail@scottellis.com.au",
+ "© 2005 Scott Ellis",
+ "http://www.scottellis.com.au/",
+ 0, //not transient
+ 0 //doesn't replace anything built-in
+};
+
+BOOL WINAPI DllMain(HINSTANCE hinstDLL,DWORD fdwReason,LPVOID lpvReserved)
+{
+ hInst=hinstDLL;
+ return TRUE;
+}
+
+extern "C" __declspec(dllexport) PLUGININFO* MirandaPluginInfo(DWORD mirandaVersion)
+{
+ return &pluginInfo;
+}
+
+
+
+
+
+unsigned long __stdcall GetIPThread(void *param) {
+ RetreiveIP();
+ return 0;
+}
+
+/*
+bool power_message = false;
+LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
+{
+ PAINTSTRUCT ps;
+ HDC hdc;
+
+ switch (message)
+ {
+ case WM_COMMAND:
+ break;
+ case WM_PAINT:
+ hdc = BeginPaint(hWnd, &ps);
+ // TODO: Add any drawing code here...
+ RECT rt;
+ GetClientRect(hWnd, &rt);
+ if(power_message)
+ DrawText(hdc, "Power message!", strlen("Power message!"), &rt, DT_CENTER);
+ else
+ DrawText(hdc, "Hello world!", strlen("Hello world!"), &rt, DT_CENTER);
+ EndPaint(hWnd, &ps);
+ break;
+ case WM_DESTROY:
+ case WM_CLOSE:
+ DestroyWindow(hWnd);
+ break;
+
+ case WM_POWERBROADCAST:
+ power_message = true;
+ InvalidateRect(hWnd, 0, TRUE);
+ break;
+
+
+ default:
+ return DefWindowProc(hWnd, message, wParam, lParam);
+ }
+ return 0;
+}
+
+
+ATOM MyRegisterClass(HINSTANCE hInstance)
+{
+ WNDCLASSEX wcex;
+
+ wcex.cbSize = sizeof(WNDCLASSEX);
+
+ wcex.style = CS_HREDRAW | CS_VREDRAW;
+ wcex.lpfnWndProc = (WNDPROC)WndProc;
+ wcex.cbClsExtra = 0;
+ wcex.cbWndExtra = 0;
+ wcex.hInstance = hInstance;
+ wcex.hIcon = 0; //LoadIcon(hInstance, (LPCTSTR)IDI_SCREENDUMP);
+ wcex.hCursor = LoadCursor(NULL, IDC_ARROW);
+ wcex.hbrBackground = (HBRUSH)(COLOR_WINDOW+1);
+ wcex.lpszMenuName = 0;//(LPCSTR)IDC_SCREENDUMP;
+ wcex.lpszClassName = "TestPowerMessagesWindowClass";
+ wcex.hIconSm = 0;//LoadIcon(wcex.hInstance, (LPCTSTR)IDI_SMALL);
+
+ return RegisterClassEx(&wcex);
+}
+
+DWORD CALLBACK MessagePumpThread(LPVOID param) {
+ CallService(MS_SYSTEM_THREAD_PUSH, 0, 0);
+
+ MyRegisterClass(hInst);
+
+ HWND hWnd = CreateWindow("TestPowerMessagesWindowClass", "Test", WS_OVERLAPPEDWINDOW, CW_USEDEFAULT, 0, CW_USEDEFAULT, 0, NULL, NULL, hInst, NULL);
+ ShowWindow(hWnd, SW_SHOW);
+ UpdateWindow(hWnd);
+
+ MSG msg;
+ // GetMessage returns -1 when hwndProgress is an invalid handle - so it exits when that window is destroyed
+ while(GetMessage(&msg, hWnd, 0, 0) > 0 && !Miranda_Terminated()) {
+ TranslateMessage(&msg);
+ DispatchMessage(&msg);
+ }
+
+ CallService(MS_SYSTEM_THREAD_POP, 0, 0);
+ return 0;
+}
+*/
+
+int OnModulesLoaded(WPARAM wParam, LPARAM lParam) {
+
+ NETLIBUSER nl_user = {0};
+ nl_user.cbSize = sizeof(nl_user);
+ nl_user.szSettingsModule = MODULE;
+ nl_user.szDescriptiveName = "External IP";
+ nl_user.flags = NUF_OUTGOING | NUF_HTTPCONNS;
+
+ hNetlibUser = (HANDLE)CallService(MS_NETLIB_REGISTERUSER, 0, (LPARAM)&nl_user);
+
+ DWORD tid;
+ CloseHandle(CreateThread(0, 0, GetIPThread, 0, 0, &tid));
+
+ //CloseHandle(CreateThread(0, 0, MessagePumpThread, 0, 0, &tid));
+
+ return 0;
+}
+
+extern "C" __declspec(dllexport) int Load(PLUGINLINK *link)
+{
+ pluginLink=link;
+ DuplicateHandle( GetCurrentProcess(), GetCurrentThread(), GetCurrentProcess(), &mainThread, THREAD_SET_CONTEXT, FALSE, 0 );
+
+ HookEvent(ME_SYSTEM_MODULESLOADED, OnModulesLoaded);
+
+ HookEvent(ME_OPT_INITIALISE, OptInit );
+
+ return 0;
+}
+
+extern "C" __declspec(dllexport) int Unload(void)
+{
+ CallService(MS_NETLIB_CLOSEHANDLE, (WPARAM)hNetlibUser, 0);
+ return 0;
+}
diff --git a/exip/options.cpp b/exip/options.cpp
new file mode 100644
index 0000000..95312bb
--- /dev/null
+++ b/exip/options.cpp
@@ -0,0 +1,62 @@
+#include "options.h"
+
+Options options;
+
+// main ping options
+static BOOL CALLBACK DlgProcOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam)
+{
+ switch ( msg ) {
+ case WM_INITDIALOG: {
+ TranslateDialogDefault( hwndDlg );
+
+ {
+ DBVARIANT dbv;
+ if(!DBGetContactSetting(0, MODULE, "ExternalIP", &dbv)) {
+ SetDlgItemText(hwndDlg, IDC_IPADDRESS, dbv.pszVal);
+ DBFreeVariant(&dbv);
+ } else {
+ SetDlgItemText(hwndDlg, IDC_IPADDRESS, Translate("Unknown"));
+ }
+ }
+
+ return FALSE;
+ }
+ case WM_COMMAND:
+ break;
+
+ case WM_NOTIFY:
+ if (((LPNMHDR)lParam)->code == PSN_APPLY ) {
+
+ SaveOptions();
+
+ return TRUE;
+ }
+ break;
+ }
+
+ return FALSE;
+}
+
+int OptInit(WPARAM wParam,LPARAM lParam)
+{
+ OPTIONSDIALOGPAGE odp = { 0 };
+#define OPTIONPAGE_OLD_SIZE2 60
+ //odp.cbSize = sizeof(odp);
+ odp.cbSize = OPTIONPAGE_OLD_SIZE2;
+ odp.position = -790000000;
+ odp.hInstance = hInst;
+ odp.pszTemplate = MAKEINTRESOURCE(IDD_OPT);
+ odp.pszTitle = Translate(MODULE);
+ odp.pszGroup = Translate("Plugins");
+ odp.flags = ODPF_BOLDGROUPS;
+ odp.pfnDlgProc = DlgProcOpts;
+ CallService( MS_OPT_ADDPAGE, wParam,( LPARAM )&odp );
+
+ return 0;
+}
+
+void LoadOptions() {
+}
+
+void SaveOptions() {
+}
diff --git a/exip/options.h b/exip/options.h
new file mode 100644
index 0000000..e54d9fa
--- /dev/null
+++ b/exip/options.h
@@ -0,0 +1,19 @@
+#ifndef _PING_OPTIONS
+#define _PING_OPTIONS
+
+#include "common.h"
+#include "resource.h"
+#include <commctrl.h>
+
+typedef struct {
+ int dummy;
+} Options;
+
+extern Options options;
+
+int OptInit(WPARAM wParam,LPARAM lParam);
+
+void LoadOptions();
+void SaveOptions();
+
+#endif \ No newline at end of file
diff --git a/exip/resource.h b/exip/resource.h
new file mode 100644
index 0000000..95d9ca6
--- /dev/null
+++ b/exip/resource.h
@@ -0,0 +1,18 @@
+//{{NO_DEPENDENCIES}}
+// Microsoft Developer Studio generated include file.
+// Used by resource.rc
+//
+#define IDD_DIALOG1 101
+#define IDD_OPT 101
+#define IDC_IPADDRESS 1001
+
+// Next default values for new objects
+//
+#ifdef APSTUDIO_INVOKED
+#ifndef APSTUDIO_READONLY_SYMBOLS
+#define _APS_NEXT_RESOURCE_VALUE 103
+#define _APS_NEXT_COMMAND_VALUE 40001
+#define _APS_NEXT_CONTROL_VALUE 1004
+#define _APS_NEXT_SYMED_VALUE 101
+#endif
+#endif
diff --git a/exip/resource.rc b/exip/resource.rc
new file mode 100644
index 0000000..f88d2a6
--- /dev/null
+++ b/exip/resource.rc
@@ -0,0 +1,96 @@
+//Microsoft Developer Studio generated resource script.
+//
+#include "resource.h"
+
+#define APSTUDIO_READONLY_SYMBOLS
+/////////////////////////////////////////////////////////////////////////////
+//
+// Generated from the TEXTINCLUDE 2 resource.
+//
+#include "afxres.h"
+
+/////////////////////////////////////////////////////////////////////////////
+#undef APSTUDIO_READONLY_SYMBOLS
+
+/////////////////////////////////////////////////////////////////////////////
+// English (Australia) resources
+
+#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENA)
+#ifdef _WIN32
+LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_AUS
+#pragma code_page(1252)
+#endif //_WIN32
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// Dialog
+//
+
+IDD_OPT DIALOG DISCARDABLE 0, 0, 269, 171
+STYLE WS_CHILD
+FONT 8, "MS Sans Serif"
+BEGIN
+ CTEXT "External IP Address:",IDC_STATIC,71,38,128,8
+ CTEXT "Static",IDC_IPADDRESS,86,70,98,23,SS_CENTERIMAGE
+END
+
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// DESIGNINFO
+//
+
+#ifdef APSTUDIO_INVOKED
+GUIDELINES DESIGNINFO DISCARDABLE
+BEGIN
+ IDD_OPT, DIALOG
+ BEGIN
+ LEFTMARGIN, 7
+ RIGHTMARGIN, 262
+ TOPMARGIN, 7
+ BOTTOMMARGIN, 164
+ END
+END
+#endif // APSTUDIO_INVOKED
+
+
+#ifdef APSTUDIO_INVOKED
+/////////////////////////////////////////////////////////////////////////////
+//
+// TEXTINCLUDE
+//
+
+1 TEXTINCLUDE DISCARDABLE
+BEGIN
+ "resource.h\0"
+END
+
+2 TEXTINCLUDE DISCARDABLE
+BEGIN
+ "#include ""afxres.h""\r\n"
+ "\0"
+END
+
+3 TEXTINCLUDE DISCARDABLE
+BEGIN
+ "\r\n"
+ "\0"
+END
+
+#endif // APSTUDIO_INVOKED
+
+#endif // English (Australia) resources
+/////////////////////////////////////////////////////////////////////////////
+
+
+
+#ifndef APSTUDIO_INVOKED
+/////////////////////////////////////////////////////////////////////////////
+//
+// Generated from the TEXTINCLUDE 3 resource.
+//
+
+
+/////////////////////////////////////////////////////////////////////////////
+#endif // not APSTUDIO_INVOKED
+