Hi. (Top posting without quoting because I'm not reacting to specific comments.)
I think Selva's approach of separate commands instead of separate fields in a single command is better for several reasons and withdraw my earlier proposal. How about (1) the ability to append messages to each other, (2) a "msg" command which concatenates a newline to the text of a message, and (3) a "msg-n " command, which doesn't, and putting the title in the command that causes display? I think that would mean there is no need to escape anything or make any OpenVPN changes, and it's easy to generate, read, parse, and process. This: echo "msg This message" echo "msg will be shown" echo "msg" echo "msg on four lines (the third line is empty)." echo "msg-window the title" would display the following in a non-modal popup window with title "the title". There is no need for an "OK" button if the window has a close button, but that could be implementation-defined behavior. ============================= This message will be shown on four lines (the third line is empty). ============================= And echo "msg-n this other message" echo "msg-n " echo "msg-n will all be" echo "msg-n" echo "msg-n displ" echo "msg-n ayed on one line." echo "msg-window the title" which would display: ========================================== this other message will all be displayed on one line. ========================================== (All spaces after the first one that follows "msg" or "msg-n" are considered part of the text, so there are lots of spaces between "message" and "will", "be" and "displayed" are separated by the second space after "msg-n" in "echo "msg-n displayed on one line", and "displ" and "ayed" are joined together because there is no such space in "msg-n ayed on one line".) What to do about wrapping lines that are too long (whatever that means : ) after concatenation would be implementation-defined. To display as a notification instead of a window, the last command would be replaced by: echo "msg-notify the title" To display a URL in a non-modal popup window with contents of URL "the_url" and title "this is the title", the sequence could be: echo "msg the_url" echo "msg-url this is the title" (One use of that would be to show a user _how_ to do something, like changing a setting in the GUI, instead of just telling them to do it.) Regarding length limits, I don't think we need to impose any limits beyond the limits imposed by OpenVPN. The OpenVPN limitation on the length of individual parameters and the limitation(s) of the buffers in the management interface are the two limits I know of. A note about those would be appropriate wherever these echo commands are documented (in the management interface doc, I assume). Keeping track of "pending" information (such as the text to be displayed to the user) must be considered: A. If a GUI disconnects from the management interface while the VPN is still connected and then later reconnects to the management interface. (Tunnelblick can do that -- we even let the user quit Tunnelblick or log out.) I'll probably have Tunnelblick save and restore any pending data in that situation. B. If the VPN disconnects or OpenVPN crashes while there is pending information, I think I'd just discard it on the assumption that it is incomplete and probably no longer relevant. Best regards, Jon ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot _______________________________________________ Openvpn-users mailing list Openvpn-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openvpn-users