|
|
|
<?xml version="1.0" encoding="utf-8"?>
|
|
|
|
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
|
|
|
<ItemGroup>
|
|
|
|
<Filter Include="Source Files">
|
|
|
|
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
|
|
|
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
|
|
|
|
</Filter>
|
|
|
|
<Filter Include="Header Files">
|
|
|
|
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
|
|
|
|
<Extensions>h;hh;hpp;hxx;hm;inl;inc;xsd</Extensions>
|
|
|
|
</Filter>
|
|
|
|
<Filter Include="Resource Files">
|
|
|
|
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
|
|
|
|
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav</Extensions>
|
|
|
|
</Filter>
|
|
|
|
</ItemGroup>
|
|
|
|
<ItemGroup>
|
|
|
|
<ClCompile Include="access.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
Parse and display messages received by echo msg commands
Process four new echo commands to construct messages to be
displayed to the user:
echo msg message-text
echo msg-n message-text
echo msg-window message-title
echo msg-notify message-title
Note: All rules of push and echo processing apply and determine
what is received as echo commands by the GUI. In addition,
'url-encoded' characters (% followed by two hex digits) are
decoded and displayed.
The message is constructed in the GUI by concatenating the text
specified in one or more "echo msg text" or "echo msg-n text"
commands. In case of "echo msg text" text is appended with a new
line. An empty text in this case will
just add a new line.
The message ends and gets displayed when one of the following
are receieved:
echo msg-window title
echo msg-notify title
where "title" becomes the title of the message window. In case of
msg-window, a modeless window shows the message, in the latter case
a notification balloon is shown.
Example: when pushed from the server:
push "echo msg I say let the world go to hell%2C"
push "echo msg I must have my cup of tea."
push "echo msg-window Notes from the underground"
will display a modeless window with title
"Notes from the underground" and a two line body
--
I say let the world go to hell,
I must have my cup of tea.
--
Note that the message itself is not quoted in the above examples
and so it relies on the server's option-parser combining
individual words into a space separated string. Number of words
on a line is limited by the maximum number of parameters allowed
in openvpn commands (16). This limitation may be avoided by quoting
the text that follows so that the option parser sees it as one
parameter.
The comma character is not allowed in pushed strings, so
it has to be sent encoded as %2C as shown above.
Such encoding of arbitrary bytes is suppored. For example,
newlines may be embedded as %0A, though discouraged. Instead
use multiple "echo msg" commands to separate lines by new line.
An example with embedded spaces and multiple lines concatenated
without a new line in between (note use of single quotes):
push "echo msg-n I swear to you gentlemen%2C that to be"
push "echo msg-n ' overly conscious is a sickness%2C ' "
push "echo msg-n a real%2C thorough sickness."
push "echo msg-notify Quote of the Day"
will show up as a notification that displays for an
OS-dependent interval as:
--
Quote of the Day
I swear to you gentlemen, that to be overly conscious
is a sickness, a real, thorough sickness.
--
where the location of the line break is automatically determined
by the notification API and is OS version-dependent.
Commands like "echo msg ..." in the config file are also
processed the same way. It gets displayed when the GUI connects
to the management interface and receives all pending echo.
Pushed message(s) get displayed when the client daemon
processes push-reply and passes on echo directives to the
GUI.
TODO: The actual window that displays the messages is
implemented in the next commit.
Signed-off-by: Selva Nair <selva.nair@gmail.com>
7 years ago
|
|
|
<ClCompile Include="echo.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
<ClCompile Include="env_set.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
<ClCompile Include="localization.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
<ClCompile Include="main.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
<ClCompile Include="manage.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
<ClCompile Include="misc.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
<ClCompile Include="openvpn.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
<ClCompile Include="openvpn_config.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
<ClCompile Include="options.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
<ClCompile Include="passphrase.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
<ClCompile Include="proxy.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
<ClCompile Include="registry.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
<ClCompile Include="save_pass.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
<ClCompile Include="scripts.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
<ClCompile Include="service.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
<ClCompile Include="tray.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
<ClCompile Include="viewlog.c">
|
|
|
|
<Filter>Source Files</Filter>
|
|
|
|
</ClCompile>
|
|
|
|
</ItemGroup>
|
|
|
|
<ItemGroup>
|
|
|
|
<ClInclude Include="access.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="chartable.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
Parse and display messages received by echo msg commands
Process four new echo commands to construct messages to be
displayed to the user:
echo msg message-text
echo msg-n message-text
echo msg-window message-title
echo msg-notify message-title
Note: All rules of push and echo processing apply and determine
what is received as echo commands by the GUI. In addition,
'url-encoded' characters (% followed by two hex digits) are
decoded and displayed.
The message is constructed in the GUI by concatenating the text
specified in one or more "echo msg text" or "echo msg-n text"
commands. In case of "echo msg text" text is appended with a new
line. An empty text in this case will
just add a new line.
The message ends and gets displayed when one of the following
are receieved:
echo msg-window title
echo msg-notify title
where "title" becomes the title of the message window. In case of
msg-window, a modeless window shows the message, in the latter case
a notification balloon is shown.
Example: when pushed from the server:
push "echo msg I say let the world go to hell%2C"
push "echo msg I must have my cup of tea."
push "echo msg-window Notes from the underground"
will display a modeless window with title
"Notes from the underground" and a two line body
--
I say let the world go to hell,
I must have my cup of tea.
--
Note that the message itself is not quoted in the above examples
and so it relies on the server's option-parser combining
individual words into a space separated string. Number of words
on a line is limited by the maximum number of parameters allowed
in openvpn commands (16). This limitation may be avoided by quoting
the text that follows so that the option parser sees it as one
parameter.
The comma character is not allowed in pushed strings, so
it has to be sent encoded as %2C as shown above.
Such encoding of arbitrary bytes is suppored. For example,
newlines may be embedded as %0A, though discouraged. Instead
use multiple "echo msg" commands to separate lines by new line.
An example with embedded spaces and multiple lines concatenated
without a new line in between (note use of single quotes):
push "echo msg-n I swear to you gentlemen%2C that to be"
push "echo msg-n ' overly conscious is a sickness%2C ' "
push "echo msg-n a real%2C thorough sickness."
push "echo msg-notify Quote of the Day"
will show up as a notification that displays for an
OS-dependent interval as:
--
Quote of the Day
I swear to you gentlemen, that to be overly conscious
is a sickness, a real, thorough sickness.
--
where the location of the line break is automatically determined
by the notification API and is OS version-dependent.
Commands like "echo msg ..." in the config file are also
processed the same way. It gets displayed when the GUI connects
to the management interface and receives all pending echo.
Pushed message(s) get displayed when the client daemon
processes push-reply and passes on echo directives to the
GUI.
TODO: The actual window that displays the messages is
implemented in the next commit.
Signed-off-by: Selva Nair <selva.nair@gmail.com>
7 years ago
|
|
|
<ClInclude Include="echo.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="env_set.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="localization.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="main.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="manage.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="misc.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="openvpn-gui-res.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="openvpn.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="openvpn_config.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="options.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="passphrase.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="proxy.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="registry.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="save_pass.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="scripts.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="service.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="tray.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="viewlog.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
<ClInclude Include="config-msvc.h">
|
|
|
|
<Filter>Header Files</Filter>
|
|
|
|
</ClInclude>
|
|
|
|
</ItemGroup>
|
|
|
|
<ItemGroup>
|
|
|
|
<ResourceCompile Include="res\openvpn-gui-res.rc">
|
|
|
|
<Filter>Resource Files</Filter>
|
|
|
|
</ResourceCompile>
|
|
|
|
</ItemGroup>
|
|
|
|
</Project>
|