All Apps and Add-ons

Why does the table not display the redirect_uri?

jhilton90
Path Finder

Can anyone tell me why my table doesn't display the redirect_uri?

 

index=keycloak customerReferenceAccountId!=SERVICE* username!=test*@test.co.uk type=LOGIN*
| stats count(eval(type="LOGIN")) as successful_login count(eval(type="LOGIN_ERROR")) as login_error by username, ipAddress
| eval percentage_failure=((successful_login/login_error)*100)
| eval percentage_failure=round('percentage_failure', 2)
| where successful_login>0 AND login_error>7
| table username, ipAddress, redirect_uri, successful_login, login_error, percentage_failure

 

Labels (2)
Tags (1)
0 Karma
1 Solution

gcusello
SplunkTrust
SplunkTrust

Hi9 @jhilton90,

because, after a stats command, you have only the fields in the stats and redirect_uri isn't one of them, you should add it to the stats command using e.g. vales as option:

index=keycloak customerReferenceAccountId!=SERVICE* username!=test*@test.co.uk type=LOGIN*
| stats 
   values(redirect_uri) AS redirect_uri 
   count(eval(type="LOGIN")) AS successful_login 
   count(eval(type="LOGIN_ERROR")) AS login_error 
   BY username ipAddress
| eval percentage_failure=((successful_login/login_error)*100)
| eval percentage_failure=round('percentage_failure', 2)
| where successful_login>0 AND login_error>7
| table username, ipAddress, redirect_uri, successful_login, login_error, percentage_failure

 Ciao.

Giuseppe

View solution in original post

gcusello
SplunkTrust
SplunkTrust

Hi9 @jhilton90,

because, after a stats command, you have only the fields in the stats and redirect_uri isn't one of them, you should add it to the stats command using e.g. vales as option:

index=keycloak customerReferenceAccountId!=SERVICE* username!=test*@test.co.uk type=LOGIN*
| stats 
   values(redirect_uri) AS redirect_uri 
   count(eval(type="LOGIN")) AS successful_login 
   count(eval(type="LOGIN_ERROR")) AS login_error 
   BY username ipAddress
| eval percentage_failure=((successful_login/login_error)*100)
| eval percentage_failure=round('percentage_failure', 2)
| where successful_login>0 AND login_error>7
| table username, ipAddress, redirect_uri, successful_login, login_error, percentage_failure

 Ciao.

Giuseppe

jhilton90
Path Finder

Ohhhhhh of course!! Thank you 🙂

0 Karma

gcusello
SplunkTrust
SplunkTrust

Hi @jhilton90,

good for you, see next time!

Ciao and happy splunking

Giuseppe

P.S.: Karma Points are appreciated 😉

0 Karma
Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

Community Content Calendar, September edition

Welcome to another insightful post from our Community Content Calendar! We're thrilled to continue bringing ...

Splunkbase Unveils New App Listing Management Public Preview

Splunkbase Unveils New App Listing Management Public PreviewWe're thrilled to announce the public preview of ...

Leveraging Automated Threat Analysis Across the Splunk Ecosystem

Are you leveraging automation to its fullest potential in your threat detection strategy?Our upcoming Security ...