07-Sep-2021
03:54
- last edited on
04-Jun-2023
19:18
by
JimmyPackets
I am logging the Java Web Token (JWT) during an Oauth login. The iRule works in general, but the JWT is cut off after 890 characters.
Cannot find any reason for it, as log entries and variables should be able to hold more than that. Here's my iRule:
when HTTP_REQUEST {
if { [HTTP::header exists Authorization] and [HTTP::header Authorization] contains "Bearer" } {
set jwt [getfield [HTTP::header Authorization] " " 2]
log local0. "JWT: Client [IP::client_addr] arrived with JWT: $jwt"
}
}
07-Sep-2021 11:26
Hello Dirken.
Take into account that log entries have a maximum size per message.
"The syslog facility is limited to logging 1024 bytes per request. Longer strings will be truncated."
REF - https://clouddocs.f5.com/api/irules/log.html
Possible solutions:
Regards,
Dario.