These are chat archives for Nithmr/ProxyHelper

30th
Jun 2016
Utkarsh Raj
@clearnote01
Jun 30 2016 06:31
Okay, i have made PAC file to work, it works with tor as well
findProxyForURL(url,host) {
return "SOCKS 127.0.0.1:9050";
}
Utkarsh Raj
@clearnote01
Jun 30 2016 06:36
in this PAC file, we just need to change the proxy values which we get by python script (parallel pinging) and we will have proxy for every case.
But this brings a major shift to the workflow! For the first time, you need to add local URL in Firefox/Chrome Preferences of the PAC file. Secondly, you may need to sometimes reload PAC file (there is a button for that firefox)
I know it's very radical but it allows us to support Windows and mostly all linux distros
Akarshit Wal
@Akarshit
Jun 30 2016 06:41
How can we support windows? Aren't we using some commands in our scripts that would work in linux only?
Akshendra Pratap Singh
@akshendra
Jun 30 2016 06:47
PAC file works only for browsers?
Utkarsh Raj
@clearnote01
Jun 30 2016 06:48
yes... it does
Akshendra Pratap Singh
@akshendra
Jun 30 2016 06:48
And how do we add it
Utkarsh Raj
@clearnote01
Jun 30 2016 06:48
but in windows as well there is option to set proxy from cli
which doesn't work for browsers
but is required for stuffs like Windows Store
and for Windows Update utility (and many more)
But pac will support browsers
Akshendra Pratap Singh
@akshendra
Jun 30 2016 06:49
Okay, but where do we keep these files and how does the browser load them?
Utkarsh Raj
@clearnote01
Jun 30 2016 06:50
are you talking about windows or linux?
We can store anywhere in the local system... it doesn't matter
For firefox: Preferences -> Advanced -> Network -> Settings
There is an option to enter path of PAC file. Enter and click reload button.
Akshendra Pratap Singh
@akshendra
Jun 30 2016 06:52
Okay
Utkarsh Raj
@clearnote01
Jun 30 2016 06:53
@Akarshit no, for the most part we are platform independent
torpinger is independent (though it will not start automatically, like in linux)
Akshendra Pratap Singh
@akshendra
Jun 30 2016 06:53
But we are going the generate the PAC file and then we have to rely on the user to add this file and reload it when changes occur.
Utkarsh Raj
@clearnote01
Jun 30 2016 06:53
and parallel pinging script should be platform independent as wel
@akshendra Yes, that is the only issue, we need to inform them to
get used to this method.
if your ff is already open then you need to click Reload button. otherwise ff will already load with PAC file and you are good to go.
They just need to set path for PAC one time.
Akshendra Pratap Singh
@akshendra
Jun 30 2016 06:56
Okay
You have tried it, and it worked?
Utkarsh Raj
@clearnote01
Jun 30 2016 06:57
yes it works.
except i hv not used python script to change PAC file, i did it manually
But really the only problem with this is that it is slightly complicated...
people have never used PAC file before and they may be overwhelmed : P
Akshendra Pratap Singh
@akshendra
Jun 30 2016 07:00
Yes, that's what I was thinking. Many of them would not be able to find where the options are located for adding this file.
Utkarsh Raj
@clearnote01
Jun 30 2016 07:16
But it helps a lot, setting socks proxy in /etc/environment is a pain and at least in Kubuntu i can't make environment variables to set as System proxy as well. With PAC we don't have to worry about anything like that.
I'm actually reallly confused myself, but it makes setting both socks proxy and http proxy so simple... that i think we should really consider this option.
Utkarsh Raj
@clearnote01
Jun 30 2016 09:56
@akshendra @Akarshit Okay... so I have found the root solution for the issue, and while I really like PAC file, we'll be going for sometime, without it (sorry windows)
The main issue was that /etc/environment variables are not read without a restart
That's why we cannot depend on it to change System proxy
So we'll have to set System proxy manually... for gnome Network Manager, it's a simple command like :- gsetting set org.gnome.system.proxy.http host 'proxy_here'
and i have also found a method to change proxy from cli for kde based systems... (#kde irc is god!)
So we have pretty decent method to set System Proxy. And we just need to user of ProxyHelper to set option use system proxy in FIREFOX from preference to do all the work : )
Akshendra Pratap Singh
@akshendra
Jun 30 2016 10:03
Cool
Akarshit Wal
@Akarshit
Jun 30 2016 10:11
Great!