* Designed, Coded, Documented by Maiko Langelaar / VE4KLM - July 23, 2009 * Updated for documents section on July 2, 2010 Introduction ------------ First of all, thanks to everyone who tried out the very first version of the web interface on my development system. After I posted the initial message to the mailing list, the amount of traffic actually startled me abit. I got alot of useful information out the exchanges, and as a result, I finally have a prototype which I am quite happy with. If you want to see it in action, feel free to visit my system at: http://www.langelaar.net:10000 You *should* be able to do anything you would normally do when you telnet or connect to JNOS as a user, even jump into SYSOP mode if you have permission. IF something does not work, let me know ! (please) Some have commented about the lack of lines when sending a message. I know it's a pain, but one thing at a time. This is what I had initially planned. I have made it so that the command field will always get the focus on page reload, you don't need the mouse, just hit the enter key. The web interface feature first arrived in the form of a patch that could only be applied to JNOS 2.0g, but since then it has been a standard part of subsequent versions of JNOS 2.0, the latest being 2.0h (at time of writing). Starting the Web Interface -------------------------- To start the web interface, use the following command : start httpvnc [tcp port] The tcp port is optional. If you do not use it, the web interface will default to using tcp port 10000. How to access the Web Interface from your browser ------------------------------------------------- Just point your browser to your system, for example: http://ve4klm.ampr.org:10000 If you have never logged in before, you will be asked to enter your callsign and your password. If you don’t have a dedicated account for the particular callsign, then use your name as the password, in which case you will receive very limited access to what commands you can run, just like when you telnet into any JNOS system. How this works and how to use it -------------------------------- After you login, you should see a page that is supposed to look like the BBS screen when you are connected to a JNOS system. The idea of the system is that you can hit (click) the enter/refresh button as many times as you want (without anything entered into the command field), which will cause the browser to refresh the display. It won't send an ENTER to the BBS, it just refreshes the display. That is a very important point to remember when using this interface. In some cases, when you put in a command and hit enter, the browser will come back before all the data for that command has had a chance to be written to the session file that the browser reads. Hitting the enter key again simply rereads the file, so if more data has been written to the session file while you were looking at the last screen, you will now see it on the screen. In other words, if it looks like the 'command did not finish', then simply hit enter as much as you need to. IF you are connecting or telneting to another station, and you want to cancel the connection, then CLICK the 'CTRL-T' and hit ENTER, which is the same as doing a CTRL-T on the console session. You can't pass CTRL-T in the command field, since CTRL-T is interpreted as an actual browser command. IF you want to clear the page or it's getting too big (note I have scrollbars on the session area), then click 'Clear' and hit ENTER, which will clear the session file. Each call has it's own session file (/tmp/.www). This takes a bit of getting used to. A very good example is when you telnet to another system. When the browser comes back to you, you may not see all of the prompt right away. No problem ! Just hit enter until you see it. You might say, 'but wait, if I hit enter too many times, it will just go to the password field'. Not true - remember, when you hit enter/refresh with an empty command field, it just refreshes the screen, and nothing is actually sent to the mailbox. It will only send the user or password if you actually enter that information into the command field and then hit enter. Once you get used to that, it's nice. I hope that makes sense. Important note about sessions ----------------------------- IF you do not use the ‘bye’ command before you terminate a browser session (or your browser crashed) - then the next time you access the web interface from the SAME IP ADDRESS, your mailbox will just come up again. Why ? Because you did not logout (bye) from it. This prototype will remember sessions based on IP address of the web client. At this time, there is no returning password, and I need to think about the security a bit more for future versions. Right now I have the maximum number of session hardcoded to 20, there is currently no code to remove a session from the session list (even if you actually use 'bye' and logout of a mailbox). That means - when you reach the maximum of 20 web users from different IP addresses, you'll have to restart JNOS (I doubt anyone will hit the limit, but be warned). This limitation will be resolved when I release the next code update. Features down the road ---------------------- I would like feedback. Adding more buttons is not difficult. The next version will allow you to define a style sheet (CSS file) so that you can pretty up the page to your own preferences. I would like to have some user defined buttons for common commands (or to repeat the last command entered). The possibilities are quite endless actually. That's all for now. The 'bbs10000.[ch]' code, like all other JNOS 2.0 additions, enhancements, bug fixes, code restructuring, and so on, is Copyright 2009-2010 by Maiko Langelaar, my amateur radio callsign is VE4KLM. For ham radio use only.