Okay. First think about what's really happening with this site.
http://relcom.net/INFO/NOC-IP/lg/lg0.html is just an html file which is defining a frameset. Its simply saying load "lg1.html" onto the left side of the browser window and load "lg2.html" onto the right side of the browser window. So this file is just telling the browser how to split the current windows into two sections and what to load into those sections. You can safely ignore this as far as your programming is concerned.
http://relcom.net/INFO/NOC-IP/lg/lg1.html is a form you fill out. It the submits to
http://relcom.net/INFO/NOC-IP/lg/lg1.cgi and it tells the browser that the response from lg1.cgi should be loaded into the right side of the browser. So in all reality, your script is only going to be dealing with
http://relcom.net/INFO/NOC-IP/lg/lg1.cgi
Now by looking at the source code for
http://relcom.net/INFO/NOC-IP/lg/lg1.html, you can dissect the form and extract it's form variables. Once you've dissected that form you no longer need lg1.html either.
So now you've eliminated all the junk in the way and you now know you only need to deal with
http://relcom.net/INFO/NOC-IP/lg/lg1.cgi.
CURL can POST form variables to the cgi script. The cgi script can't stop you from doing this. It can however try and determine if that's what your doing and give you an error if it suspects your doing it. Fortunately CURL also has the ability to control all headers and meta data that cgi script may be looking at. So it might look at the http-refer header to see if you are direct submitting or actually using their form. They can look at the agent header to see if you actually using a browser. etc etc etc.
Now your only job (as I've broken down all the research for you already) is determine what that cgi script is looking for in the headers to help it determine if you are posting directly (via CURL) or through their own web page.
And I went ahead and figured that out for you too. Below is a curl command that works perfectly (I've tested it).
Code: Select all
curl -e "http://relcom.net/INFO/NOC-IP/lg/lg1.html" -F "ROUTER=M9-16&query=trace&addr=64.233.167.99&submit=Submit" http://relcom.net/INFO/NOC-IP/lg/lg1.cgi
BTW this all a one line command, do not put a line break anywhere in it.
Simply change the value after query= if you want a different action than trace and change the IP address after addr= with your own ip addresses (one at a time).