Adding support for authentication proxies

This change allows Notnoop/java-apns to work with proxies that require
authentication. This code change is only meant to support Basic, Digest
and NTLM Authentication schemes.
Fixing incorrect check for invalid port number.

Valid port numbers are between 0 and 65535. Anything less than 0 is
considered invalid.
Merge branch 'auth-proxy'