Forum Discussion
Any incoming request (not just the initial connection)
One of the software guys has presented the following to me. Any help would be much appreciated!
"I think part of what might be going on with this is that HTTP 1.1 does not require a new connection with each request. This means that a tcp connection is made, but then there may be multiple request/response pairs that are sent. If the security subject is only being passed through on the initial connection, then you would get the behavior we are seeing. (Note that I am trying to guess backwards from symptom to problem…not something I like doing).
What we actually need is for any incoming request (not just the initial connection) the subject header from the certificate needs to be added.
I guess in this direction because Bill is telling me that when he restarts SOAPUI, it will go back to working once for him. This tells me that either:
1.In spite of SOAPUI saying that it is going to close connections after each request…it isn’t.
2. The F5 is doing something overly smart in relation to Bill and his session (unlikely)."
Below is the irule currently assigned to the VIP:
when CLIENTSSL_CLIENTCERT {
set cert_subject [X509::subject [SSL::cert 0]]
if { $cert_subject == "" }
{ log "[IP::client_addr]:[TCP::client_port]: No client cert found!"}
}
when HTTP_REQUEST {
if { [info exist cert_subject] } {
HTTP::header insert SSLClientCertSubject $cert_subject
return
}
}
3 Replies
- nitass
Employee
i understand HTTP_REQUEST is executed on every request (not only initial one). can you add some log command?[root@ve10:Active] config b virtual bar list virtual bar { snat automap pool foo destination 172.28.19.79:443 ip protocol 6 rules myrule profiles { clientssl { clientside } http {} tcp {} } } [root@ve10:Active] config b pool foo list pool foo { members 200.200.200.101:80 {} } [root@ve10:Active] config b rule myrule list rule myrule { when CLIENT_ACCEPTED { log local0. "--" } when CLIENTSSL_HANDSHAKE { log local0. "--" } when HTTP_REQUEST { log local0. "--" log local0. "client [IP::client_addr]:[TCP::client_port] | request [HTTP::uri]" } } [root@ve10:Active] config cat /var/log/ltm Oct 27 11:06:28 local/tmm info tmm[7926]: Rule myrule : -- Oct 27 11:06:28 local/tmm info tmm[7926]: Rule myrule : -- Oct 27 11:06:30 local/tmm info tmm[7926]: Rule myrule : -- Oct 27 11:06:30 local/tmm info tmm[7926]: Rule myrule : -- Oct 27 11:06:31 local/tmm info tmm[7926]: Rule myrule : -- Oct 27 11:06:31 local/tmm info tmm[7926]: Rule myrule : -- Oct 27 11:06:31 local/tmm info tmm[7926]: Rule myrule : -- Oct 27 11:06:31 local/tmm info tmm[7926]: Rule myrule : client 172.18.205.28:46908 | request /index.html Oct 27 11:06:31 local/tmm info tmm[7926]: Rule myrule : -- Oct 27 11:06:31 local/tmm info tmm[7926]: Rule myrule : client 172.18.205.28:46908 | request /f5.gif Oct 27 11:06:32 local/tmm info tmm[7926]: Rule myrule : -- Oct 27 11:06:32 local/tmm info tmm[7926]: Rule myrule : client 172.18.205.28:46908 | request /favicon.ico Oct 27 11:06:32 local/tmm info tmm[7926]: Rule myrule : -- Oct 27 11:06:32 local/tmm info tmm[7926]: Rule myrule : client 172.18.205.28:46908 | request /favicon.ico
- RiverFish
Altostratus
Thanks! This will give us more visibility as to what is happening. - hoolio
Cirrostratus
Hi tzemler,when HTTP_REQUEST { if { [SSL::cert 0] ne "" and [set cert_subject [X509::subject [SSL::cert 0]]] ne ""} { HTTP::header insert SSLClientCertSubject $cert_subject } }
Recent Discussions
Related Content
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com