All Apps and Add-ons

SSL Certificate Lookup - multiple with custom port

svarendorff
Explorer

After some help. Is there any way to get this to use a custom port for the 2 server that use a non 443 port?

| makeresults
| eval dest="url1,url2,url3", dest = split (dest,",")
| mvexpand dest
| lookup sslcert_lookup dest OUTPUT ssl_subject_common_name ssl_subject_alt_name ssl_end_time ssl_validity_window
| eval ssl_subject_alt_name = split(ssl_subject_alt_name,"|")
| eval days_left = round(ssl_validity_window/86400)
| table ssl_subject_common_name ssl_subject_alt_name days_left ssl_issuer_common_name
| sort days_left

 

I tried adding the port to the first eval e.g.

| eval dest="url1,url2,url3",  dest_port=8443 , dest = split (dest,",")

 

Would be great if both the standard and custom could be returned together.

Labels (1)
0 Karma

svarendorff
Explorer

Figured it out.

| makeresults
| eval dest="url1,url2,url3", dest_port=8443, dest = split (dest,",")
| mvexpand dest
| `sslcert(dest, dest_port)`
| lookup sslcert_lookup dest, dest_port OUTPUT ssl_subject_common_name ssl_subject_alt_name ssl_end_time ssl_validity_window
| eval ssl_subject_alt_name = split(ssl_subject_alt_name,"|")
| eval days_left = round(ssl_validity_window/86400)
| table ssl_subject_common_name ssl_subject_alt_name days_left
| sort days_left

0 Karma
Get Updates on the Splunk Community!

.conf25 Community Recap

Hello Splunkers, And just like that, .conf25 is in the books! What an incredible few days — full of learning, ...

Splunk App Developers | .conf25 Recap & What’s Next

If you stopped by the Builder Bar at .conf25 this year, thank you! The retro tech beer garden vibes were ...

Congratulations to the 2025-2026 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...