-
-
Notifications
You must be signed in to change notification settings - Fork 274
Description
JavaMail only supports anonymous SOCKS proxy.
The only way to add this capability is by incorporating a SOCKS server into Simple Java Mail: it would be started when an email is being sent through Mailer.sendMail()
and accepts the anonymous proxy connection from JavaMail on localhost and relays it to a proper proxy by also including a proxy client in Simple Java Mail which can connect to any proxy (HTTP, SOCKS, anonymous and authenticated).
So:
Mailer.sendMail() -> JavaMail Transport.send() (supports only anonymous SOCKS) -> Simple Java Mail temp proxy (anonymous SOCKS) -> Simple Java Mail proxy client -> the real proxy through which you want to go (HTTP, SOCKS, anonymous and authenticated)
But I don't want to balloon this library into the megabytes, because some open source proxy library included guava and netty and whatnot. Simple Java Mail is to remain a sleak library that includes everything in itself (by using the maven shade plugin).