<div dir="ltr"><div>Hello Alex,</div><div><br></div><div>thank you for your answer. I was little bit puzzled since I haven't got any error when using "clientca" with "http_port". I thought, maybe it was somehow possible, beyond my understanding. :)</div><div><br></div><div>The reason why I didn't respond immediately, because I wanted to test everything with the "https_port" configuration.</div><div><br></div><div>Now my configuration looks like this:</div><div><br></div><div>> https_port 443 tls-cert=/etc/squid/certs/new-squid.cert tls-key=/etc/squid/certs/new-squid.key clientca=/etc/squid/certs/autn.pem capath=/etc/squid/certs/CAs sslcontext=id</div><div><br></div><div>This works...</div><div><br></div><div>What I'm trying to do is access control with *user_cert* ACL based on CN information.</div><div><br></div><div>My ACL configuration is super minimal:</div><div><br></div><div>> acl ssl_auth user_cert CN "/etc/squid/<a href="http://allowed.cn">allowed.cn</a>"<br>> http_access allow ssl_auth</div><div>><br></div><div>> http_access deny all</div><div><br></div><div>
File "/etc/squid/<a href="http://allowed.cn">allowed.cn</a>" contains one row/entry: "Doe John PKI 1234567890" (without quotes)<br></div><div><br></div><div>However this doesn't work.</div><div><br></div><div>From the cache.log, it is visible that client certificate information is fetched:</div><div><br></div><div>> clientNegotiateSSL: New session 0x11415a0 on FD 12 (10.x.x.x:60308)<br>> retrieveNegotiatedInfo: SSL connection info on FD 12 SSL version TLS/1.2 negotiated cipher AES128-GCM-SHA256<br>> clientNegotiateSSL: FD 12 client certificate: subject: /DC=tst/CN=Doe John PKI 1234567890<br>> clientNegotiateSSL: FD 12 client certificate: issuer: /DC=com/DC=tst/DC=PKI/CN=CA-AUTH-01<br>> Server.cc(90) readSomeData: conn7 local=10.x.x.x:443 remote=10.x.x.x:60308 FD 12 flags=1: reading request...</div><div><br></div><div>From the cache.log is as well visible that ssl_auth ACL is checked, but there is NO MATCH:</div><div><br></div><div>> Acl.cc(124) matches: checking http_access<br>> Checklist.cc(398) bannedAction: Action 'ALLOWED/0' is not banned<br>> Acl.cc(124) matches: checking http_access#1<br>> Acl.cc(124) matches: checking ssl_auth     < --- Access list<br>> <br>> CertificateData.cc(68) match: CN=Doe John PKI 1234567890   < --- Client certificate CN<br>> <br>> MemBlob.cc(56) MemBlob: constructed, this=0x14dccc0 id=blob1388 reserveSize=35<br>> MemBlob.cc(101) memAlloc: blob1388 memAlloc: requested=35, received=40<br>> SBuf.cc(866) reAlloc: SBuf5096 new store capacity: 40<br>> StringData.cc(33) match: aclMatchStringList: checking 'Doe John PKI 1234567890'<br>> <br>> StringData.cc(36) match: aclMatchStringList: 'Doe John PKI 1234567890' NOT found   
< --- doesn't match<br>> <br>> Acl.cc(151) matches: checked: ssl_auth = 0<br>> Acl.cc(151) matches: checked: http_access#1 = 0<br><br></div><div><br></div><div>I'm really not sure what I have missed...</div><div>I tried to put CN directly in the ACL, so with no reference to thefile.</div><div>I tried to put single and double quotes around CN in <a href="http://allowed.cn">allowed.cn</a> file, as well.<br></div><div><br></div><div>Could you please help me further? What am I doing wrong here?</div><div><br></div><div>Thank you and regards,</div><div>Neven<br></div><div><br></div></div>