<html><head></head><body><div class="ydpb0755094yahoo-style-wrap" style="font-family:courier new, courier, monaco, monospace, sans-serif;font-size:10px;"><div dir="ltr" data-setdir="false">It is known, that RosComNadzor is blocking certain domains/IPs.</div><div dir="ltr" data-setdir="false">Often it is bloking by rewriting url in place, i.e., when I try to access http(s)://blocked.domain, it changes in the location bar of the browser to <a href="http://eais.rkn.gov.ru" rel="nofollow" target="_blank" class="">http://eais.rkn.gov.ru</a> (RosComNadzor's bloking page) in place, i.e. no ability to click the back button to see which url was blocked. RosComNadzor's blocking page has no mention of what url was blocked either. When I try to use Firefox'es or Chrom(e|ium)'s Developer Tools's Network section on blocked page to see, if I can find out what page was blocked by looking at Referer param of the HTTP header, it's already too late, because those Network sections don't show anything, because they were not started in advance, before the page was blocked. I have to reload the page, in order to see something in that networking section, but I would be reloading <a href="http://eais.rkn.gov.ru" rel="nofollow" target="_blank">http://eais.rkn.gov.ru</a> page already, not the required url and <a href="http://eais.rkn.gov.ru" rel="nofollow" target="_blank">http://eais.rkn.gov.ru</a> doesn't show any Referer in HTTP header, because, it's reloaded in place, and did not come from some other page. It's frustrating, because, when you have many tabs open, you have no way of knowing, which url's were blocked and no way of recovering the blocked address. squid's access log doesn't help either, because you can't tell for certain, that the log entry, previous to log entry with <a href="http://eais.rkn.gov.ru" rel="nofollow" target="_blank">http://eais.rkn.gov.ru</a> address belongs to the same tab of the browser.<br></div><div><br></div><div dir="ltr" data-setdir="false">I've found out, one of the urls, that is being blocked, because it happened in front of my eyes, so I've tested it with:</div><div dir="ltr" data-setdir="false">$ <span>curl -v 'http://blocked.domain/'</span></div><div dir="ltr" data-setdir="false"><span><br></span></div><div dir="ltr" data-setdir="false"><span>I got the dump:</span></div><div dir="ltr" data-setdir="false"><span>---DUMP START---<br></span></div><div dir="ltr" data-setdir="false"><div dir="ltr" data-setdir="false">*   Trying 127.0.0.1...<br>* Connected to 127.0.0.1 (127.0.0.1) port 3128 (#0)<br><div>> GET http://<span><span>blocked.domain</span></span>/ HTTP/1.1</div><div>> Host:  <span><span>blocked.domain</span></span></div>> User-Agent: curl/7.47.0<br>> Accept: */*<br>> Proxy-Connection: Keep-Alive<br>><br>< HTTP/1.1 302 Found<br>< Date: Wed, 11 Sep 2019 08:48:44 GMT<br>< Content-Length: 205<br>< Location: http://eais.rkn.gov.ru<br>< Content-Type: text/html; charset=UTF-8<br>< X-Cache: MISS from ls02800008008u<br>< X-Cache-Lookup: MISS from ls02800008008u:3128<br>< X-Cache: MISS from ws02800008006<br>< X-Cache-Lookup: MISS from ws02800008006:3128<br>< X-Cache: MISS from cooldown-nb<br>< X-Cache-Lookup: MISS from cooldown-nb:3128<br>< Via: 1.1 ls02800008008u (squid/3.5.12), 1.1 ws02800008006 (squid/3.5.27), 1.1 cooldown-nb (squid/3.5.12)<br>< Connection: keep-alive<br><<br><HTML><HEAD><meta http-equiv="content-type" content="text/html;charset=utf-8"><br><TITLE>302 Found</TITLE></HEAD><BODY><br><H1>302 Found</H1><br>The document has moved<br><A HREF="http://eais.rkn.gov.ru">here</A><br><div>* Connection #0 to host 127.0.0.1 left intact</div><div dir="ltr" data-setdir="false">---DUMP END---<br></div><div><br></div><div dir="ltr" data-setdir="false">So, there is a 302 redirect, that happens automatically:</div><div dir="ltr" data-setdir="false"><span>Location: <a href="http://eais.rkn.gov.ru" rel="nofollow" target="_blank">http://eais.rkn.gov.ru</a><br></span></div><div dir="ltr" data-setdir="false"><br></div><div dir="ltr" data-setdir="false"><div dir="ltr" data-setdir="false">How do I disable 302 redirect in squid, but only to <span><a href="http://eais.rkn.gov.ru" rel="nofollow" target="_blank">http://eais.rkn.gov.ru</a></span> address, so, in browser I see that page is blocked, but at least, I don't loose the information of what page is blocked, because it's not automatically redirected to <span><a href="http://eais.rkn.gov.ru" rel="nofollow" target="_blank">http://eais.rkn.gov.ru</a></span> and the location in the browser showing the original url?</div><div dir="ltr" data-setdir="false"><br></div><div dir="ltr" data-setdir="false">After I've wrote my question, I thought, if it's possible to to do it with:</div><div dir="ltr" data-setdir="false"><span><br></span></div><div dir="ltr" data-setdir="false"><span>acl sites_blocking_redirect url_regex <a href="http://eais.rkn.gov.ru" rel="nofollow" target="_blank">eais\.rkn\.gov\.ru</a><br></span></div><div dir="ltr" data-setdir="false"><div dir="ltr" data-setdir="false"><span>reply_header_access Location deny sites_blocking_redirect</span></div><div dir="ltr" data-setdir="false"><span><br></span></div><div dir="ltr" data-setdir="false"><span>Is it a workable or the correct way to do it, so it solves my problem?<br></span></div><span></span></div><span></span></div></div></div></div></body></html>