Fixes sixohsix/twitter#154: application-only authentication with oauth2 support

Fixes sixohsix/twitter#154: application-only authentication with oauth2 support. Tested on python 2.7 and python 3.3.