Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

app-layer-ssl: decode serial number from certificate #2589

Closed
wants to merge 7 commits into from

Conversation

thus
Copy link
Contributor

@thus thus commented Feb 21, 2017

Decode serial number from certificates. This pull request adds the following:

  • Logging of certificate serial numbers (tls-log and tls eve-log)
  • Mpm keyword: tls_cert_serial
  • Lua function TlsGetCertSerial()

https://redmine.openinfosecfoundation.org/issues/2006

Prscript:

Add function LuaGetCertSerial to print serial number from TLS
certificate.

Example:

function log (args)
    serial = TlsGetCertSerial()

    if serial then
        file:write(serial .. "\n");
        file:flush()
    end
end
Match on TLS certificate serial number using tls_cert_serial
keyword, e.g.:

alert tls any any -> any any (msg:"TLS cert serial test";
        tls_cert_serial; content:"5C:19:B7:B1:32:3B:1C:A1";
        sid:12345;)
@inliniac
Copy link
Contributor

Merged through #2592, thanks Mats!

@inliniac inliniac closed this Feb 21, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants