Is it possible to make a Direct connection to the Internet without using a Proxy.
Consider a case that my Organization has a Proxy and I use the DIRECT option given in the Java Proxy class.
SocketAddress addr = new
InetSocketAddress("webcache.mydomain.com", 8080);
Proxy proxy = new Proxy(Proxy.Type.DIRECT, addr);
If you go by the documentation it states
DIRECT which represents a direct connection, or absence of proxy.
Which is exactly the way it behaves. When I use this option, I dont have to give any Proxy details and I can access the content from the Internet.
I have three questions
- As per my understanding if an Organization has a Proxy, all network
traffic should get routed through the Proxy. No one should be able
to access the Network directly ? - I also noted that if I remove the Proxy details from IE, I can not
access the Web 🙁 How can Java still do it ? - If in any Organization you can access both with the Proxy and
Directly, how does the firewall block certain sites ? How does the
firewall even work ?
Thanks in advance.
Not all Network traffic goes through a Proxy, if your Organization has a Proxy. You can still go ahead and establish a Direct connection to the Internet. Mostly the Organizations will block Direct connections and force you to use Proxies. Some times they might allow you to have a Restricted Direct connection, which allows certain URL’s and denies other ones.