I've written a few main() functions in my time. They usually have a structure roughly like this:
This serves as a long usage message.
# parse command line options
opts, args = getopt.getopt(sys.argv[1:], "h", ["help"])
except getopt.error, msg:
print "for help use --help"
# process options
for o, a in opts:
if o in ("-h", "--help"):
# process arguments
for arg in args:
process(arg) # process() is defined elsewhere
if __name__ == "__main__":
A SQL Injection is a type of virus that you type into a user input field that allows access to the database that the field is connected to. If done right a SQL Injection can leave devastation on a computer and site.
SQL Injection's can be done in a variety of ways and forms, and they are becoming increasingly dangerous via the web.
Different SQL codes can be used to override SQL database code and gain information.
SELECT user from users where password = 'pass123' OR email = 'firstname.lastname@example.org'