Hi, I am writing a program that access a POP3 and SMTP mail account using the JavaMail API. The code that I use requires a direct connection between the machine where the program is executing and the Internet. If the machine where the program is executing accesses the web via a proxy server, what necessary information is required and settings should be done for the program to be able to do so? Also I want the settings, if any, to be performed in the program itself. In other words the proxy settings should be made only if the necessary information is provided.
Hi All, I searched for accessing mail server via proxy and found the following on JGuru.com.
Question How do I configure JavaMail to work through my proxy server? Answer Proxy servers redirect HTTP connections, not JavaMail connections. In order to connect from behind a firewall for POP3, IMAP, and SMTP access, you need to connect to a SOCKS server. Your sys admin should provide you with SOCKS client software, to install on your client machine. (Hummingbird, for instance, for Windows; various clients for Solaris; I think Linux, at least RedHat, already comes with a SOCKS client?) The SOCKS versions have to match, on the client and SOCKS server. It's transparent to network applications, e.g. they just think they are making normal connections, but the TCP stack internally tunnels these through SOCKS instead. So the only thing to configure is the SOCKS client software on the host.
Now can anyone help me with this? I want to know how do I make a connection to a SOCKS server in my program?