Posted By

scyclops on 08/28/07


Tagged

networking wireless gatech


Versions (?)


Advertising

Website Promotion DIRECTORY is a crucial factor for all websites that need to gain better organic search engine rankings and increase website traffic.
Submitting your website as part of your Web Promotion strategy to our SEO friendly and high traffic Business Directory for review is an excellent way to gain a valuable backlink and increase your websites visibility online.

Submit Site


Who likes this?

1 person has marked this snippet as a favorite

copyleft


Georgia Tech LAWN login script


Published in: Python 






URL: http://andrewtrusty.com/

A quick and simple script to allow people to log onto the Georgia Tech wireless network without opening a browser. Pass your login details on the command line or enter them once you run the script.

Sources: - http://www.lawn.gatech.edu/help/command_line.html

Expand | Embed | Plain Text
  1. import sys, getpass, urllib
  2.  
  3. separator = "-----------------------------"
  4. print(separator +
  5. "\n Georgia Tech Lawn Login\n" +
  6. separator)
  7.  
  8. if len(sys.argv) >= 2:
  9. username = sys.argv[0]
  10. password = sys.argv[1]
  11. if len(sys.argv) >= 3:
  12. iss = sys.argv[2]
  13. else:
  14. iss = ""
  15. else:
  16. username = raw_input("Username: ")
  17. password = getpass.getpass()
  18. iss = raw_input("Enable Inbound Security? ")
  19.  
  20. if iss.strip() in ("", "true", "True", "1", "y", "Y", "yes", "Yes"):
  21. iss = "true"
  22. else:
  23. iss = "false"
  24.  
  25. try:
  26. print "\nAttempting to login..."
  27. data = urllib.urlopen('https://auth.lawn.gatech.edu/index.php',
  28. 'username=' + username +
  29. '&password=' + password +
  30. '&iss=' + iss +
  31. '&output=text')
  32. print separator
  33. print data.read()
  34. except IOError, e:
  35. print "IOError:", e

Report this snippet 

Comments

RSS Icon Subscribe to comments
Posted By: jakswa on February 5, 2009

I just wanted to give a quick thanks, I used this script while at Tech for a couple years, and then just recently am adapting it to work on GSU's login system: http://snipplr.com/view/11887/gsu-login/

So, hope it's alright I 'stole' your general idea, let me know if you want me to cite you in my code or something.

You need to login to post a comment.