OPNsense Forum

English Forums => Web Proxy Filtering and Caching => Topic started by: HWB on April 09, 2019, 11:08:34 AM

Title: Proxy-Server Authentication after PC-Reboot
Post by: HWB on April 09, 2019, 11:08:34 AM
I use opnsense as a Proxy-Server.

I want, that only allowed users can connect via the Proxy to the Internet (on every PC in the Network), so i use a Local Database user to authenticate the connection.

I have already:



Here is the problem: If i use this way to authentificate to the proxy, there is only a option to activate a TTL like one Hour etc.
But i want that if i cut the connection between PC and Proxy for example after a reboot of my pc or changing the proxy settings on it, that i have to authenticate the local databasse user again.

I hope it is understandable what I am trying to say.


Is there a way to enable, that if a user is disconnected from proxy he has to authentificate again, without waiting an 1 Hour?

If possible without a Radius Server.

Thanks
Title: Re: Proxy-Server Authentication after PC-Reboot
Post by: hbc on April 10, 2019, 01:04:21 PM
HTTP is a stateless protocol. Your proxy server will not recognize whether the user is rebooting its device and no requests are coming or he is just idle, off from pc or just doing something else that does not generate web traffic?

QuoteIf a user is authenticated at the proxy you cannot "log out" and re-authenticate. The user usually has to close and re-open the browser windows to be able to re-login at the proxy.

See here:
https://wiki.squid-cache.org/Features/Authentication#Does_Squid_cache_authentication_lookups.3F (https://wiki.squid-cache.org/Features/Authentication#Does_Squid_cache_authentication_lookups.3F)

Since a reboot is like closing the browser and if you changed the credential caching to nothing, then it must be your browser that caches credentials between sessions/reboots.