<div dir="ltr">>>
When you enter "<a href="https://www.example.com:8888/test.php" rel="noreferrer" target="_blank">https://www.example.com:8888/test.php</a>" to your browser, it <br>
>>asks proxy server to "CONNECT <a href="http://www.example.com:8888" rel="noreferrer" target="_blank">www.example.com:8888</a>" and browser handles the <br><div>
>>SSL negotiation and further communication itself. <br></div><div><br></div><div>what you are saying It's very interesting, 
infact previously I understood
CONNECT
method was invoked both by http and by https protocols.</div><div>You are saying CONNECT method is invoked only if protocol is https, while if you type http://site:port, no 
CONNECT method 

is invoked. </div><div>Right ?  <br></div><div><br></div></div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">Il giorno mar 29 apr 2025 alle ore 16:36 Matus UHLAR - fantomas <<a href="mailto:uhlar@fantomas.sk">uhlar@fantomas.sk</a>> ha scritto:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On 29.04.25 08:54, Renzo Marengo wrote:<br>
>When client uses CONNECT directive I understand that proxy establishes<br>
>tunnel to destination host on specified port<br>
><br>
>e.g.<br>
><a href="http://www.example.com:8888/test.php" rel="noreferrer" target="_blank">http://www.example.com:8888/test.php</a><br>
><a href="https://www.example.com:8888/test.php" rel="noreferrer" target="_blank">https://www.example.com:8888/test.php</a><br>
><br>
>1. I don't understand if this occurs both in presence of http and https<br>
>requests, The request (using CONNECT method) can be http or https ?<br>
<br>
<br>
When you enter "<a href="http://www.example.com:8888/test.php" rel="noreferrer" target="_blank">http://www.example.com:8888/test.php</a>" into your browser, <br>
your browser asks proxy server for "<a href="http://www.example.com:8888/test.php" rel="noreferrer" target="_blank">http://www.example.com:8888/test.php</a>"<br>
- it delegates fetching the content to proxy.<br>
<br>
When you enter "<a href="https://www.example.com:8888/test.php" rel="noreferrer" target="_blank">https://www.example.com:8888/test.php</a>" to your browser, it <br>
asks proxy server to "CONNET <a href="http://www.example.com:8888" rel="noreferrer" target="_blank">www.example.com:8888</a>" and browser handles the <br>
SSL negotiation and further communication itself.<br>
<br>
This way, you can tunnel different protocols through the proxy, not just <br>
HTTP (squid must be able to allow it, the destination ports are usually <br>
restricted via "https_port" acl).<br>
<br>
>2.  if In both cases CONNECT method is invoked but how I can discover<br>
>protocol (http, https) looking for inside access.log ?<br>
>A.B.C.D TCP_TUNNEL/200 7085 CONNECT <a href="http://mtalk.google.com:5228" rel="noreferrer" target="_blank">mtalk.google.com:5228</a> - HIER_DIRECT/<br>
>142.251.18.188<br>
><br>
>I see only info about destination host and port but no http/https protocol<br>
>is referenced.<br>
<br>
<br>
In this case, client A.B.C.D asked the proxy to "CONNECT <br>
<a href="http://mtalk.google.com:5228" rel="noreferrer" target="_blank">mtalk.google.com:5228</a>" and the proxy fullfilled the request.<br>
In case of CONNECT requests, the proxy has no idea what data flow through <br>
the server. Afaik <a href="http://mtalk.google.com:5228" rel="noreferrer" target="_blank">mtalk.google.com:5228</a> is used for google/firebase cloud <br>
messaging.<br>
<br>
-- <br>
Matus UHLAR - fantomas, <a href="mailto:uhlar@fantomas.sk" target="_blank">uhlar@fantomas.sk</a> ; <a href="http://www.fantomas.sk/" rel="noreferrer" target="_blank">http://www.fantomas.sk/</a><br>
Warning: I wish NOT to receive e-mail advertising to this address.<br>
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.<br>
    One OS to rule them all, One OS to find them,<br>
One OS to bring them all and into darkness bind them<br>
_______________________________________________<br>
squid-users mailing list<br>
<a href="mailto:squid-users@lists.squid-cache.org" target="_blank">squid-users@lists.squid-cache.org</a><br>
<a href="https://lists.squid-cache.org/listinfo/squid-users" rel="noreferrer" target="_blank">https://lists.squid-cache.org/listinfo/squid-users</a><br>
</blockquote></div>