The ZIP file contains 3 executables that are required for installation.
1) vcredist_x86(2).exe - Microsoft C++ 2008 Redistributables
2) Win32OpenSSL-0_9_8k.exe - Win32 Port of OpenSSL
3) lendvend.exe - The actual LendVend robot
OpenSSL has a hard dependency on the Microsoft C++ 2008 Redistributables, in turn, lendvend.exe has a hard dependancy on the OpenSSL libraries. This is required because the site speaks only HTTPS:// as opposed to just HTTP://. These dependencies should be observed in order.
Installation
The first two programs require administrative privileges. For example, OpenSSL will require administrative consent to install to C:\OpenSSL\. Be sure to install it this way.
1) Open/Install vcredist_x86(2).exe.
2) Open/Install Win32OpenSSL-0_9_8k.exe. The default options during the installation should be sufficient. Please be sure to select the option to put OpenSSL library files in the openSSL bin directory, as opposed to the windows directory.
3) Launch lendvend.exe.
Caveats
It is possible to receive an error message saying windows can not find libeay32.dll. This is caused by some sort of pathing issue on the system. If this error pops up I would need to roll another copy of lendvend.exe to explicitly include libeay32.dll in the PAR.
The default options for this script are a 1 second refresh time, and a max_order count of 3 orders per run. This is configurable. To do this, you will need to click start, click run, type 'cmd' and hit enter. You will need to change directories to where lendvend.exe is located. For example, you would type:
cd C:\Users\Porter\
When in the same directory as lendvend.exe you will be able to execute the program by calling it directly. It does support the --help option.
C:\Users\Porter> lendvend.exe --help
VenderLend Robot: ./lendvend [options]
OPTIONS:
[-d] Debug support. Spits out page files. [--debug]
Default: Console mode
[-i] Update interval. Default is 05 [--interval]
Default: 10 seconds
[-v] Verbose output [--verbose]
Default: Off
[-m] Max number of orders to grab before exiting. [--max]
Default: 3The verbose and debug flags are there to aid the development process.
The --verbose flag adds some additional output that complains when the site throws it something it's not expecting. For example, the FORM handler on the queue.aspx page runs html entities on the action="" portion. So you end up with something like & as opposed to just an ampersand (&). At present the robot disregards these things and posts to the correct URL.
The --debug flag will drop flat .txt files in it's directory when it sees an order. This text file contains the request and response data objects which help me troubleshoot what is going on. It also contains the HTML on the queue page and the Pipeline page after it grabs an order. If the site is changed in the future in such a way that the robot breaks, I would need to run it with the --debug flag to figure the issue out.
The flags of interest to the user are -i (--interval) and -m (--max). They are used as follows:
C:\Users\Porter> lendvend.exe -i 5 -m 7 Successful Login! Found no orders. Sleeping 5 seconds. Currently found 0 of 7 orders. Found no orders. Sleeping 5 seconds. Currently found 0 of 7 orders.
Notice the Sleep time is represented by the -i flag and the orders is represented by the -m flag respectively.
Stopping the robot
If you've run the robot by just double clicking on it, you may close the black window that pops up.
If you've run the robot from the command line (see above), you may close the black window, or hold down the CTRL key and the letter 'C'. This will send an interrupt to the program that will tell it to exit.
Please email me if you have any questions.