Python

Commonly used data types

  • Strings: item="towel"

  • Boolean: b=True

  • Integer: answer=42

  • Float: ration=3.14678

Commonly used Syntax

  • if

  • elif

  • else

Commonly used Function

  • input() - interactive keyboard input from a user

General Web Libraries

  • urillib

  • uribil2

  • urllib3

  • httplib

  • httplib2

  • Requests (Best)

    • Supports Authentication (Basic,Digest,Kerberos,NTLM,AWS,OAuth1)

    • Handles SSL

    • Export specific header

      • r.headers['server'], r.headers['user-agent']

Learn Python Basics

References

Violent Python code converted to Python3: https://github.com/EONRaider/violent-python3 kojibhy's Python Scripts: https://github.com/kojibhy/Python-scripts| PeterMosmans's Python Security Scripts: https://github.com/PeterMosmans/security-scripts

Last updated