Getting Data In

using source in props.conf to break the below event based on realm .

Sujithkumarkb
Observer

I am trying to break the event based on the realm in the below example.
My sourcetype "Iam_logs" is defined globally to almost 10 sources.

Now i want to edit the extraction for one of the source="/opt/app/logs/openam/authentication.audit.json" only.
I have defined the props like below
[Forgerock]
NO_BINARY_CHECK = true
SHOULD_LINEMERGE = false
LINE_BREAKER=([\r\n]+)(?=$|{"realm)
disabled = false
pulldown_type = 1

[source::"/opt/app/logs/openam/authentication.audit.json"]
sourcetype=Forgerock
SHOULD_LINEMERGE=false

I have updated this in cluster master and tried to distribute it to the peers.
./splunk validate cluster-bundle
./splunk validate cluster-bundle --check-restart
./splunk show cluster-bundle-status
./splunk apply cluster-bundle

neither the sourcetype reflects ,nor does the events are broke..

Can anyone advice

Sample event :
{"realm":"/humapp","transactionId":"--462e-950b--80936045","component":"Authentication","eventName":"AM-LOGIN-MODULE-COMPLETED","result":"FAILED","entries":[{"moduleId":"LDAP","info":{"authControlFlag":"REQUIRED","moduleClass":"LDAP","failureReason":"INVALID_PASSWORD","ipAddress":"","authLevel":"0"}}],"userId":"[email protected],ou=user,o=app,ou=services,dc=openam,dc=,dc=com","principal":["@gmail.com"],"timestamp":"2019-07-18T10:16:16.940Z","trackingIds":["ID"],"_id":"2e-950b-0f75fd67a3ae-80936047"}

{"realm":"/humapp","transactionId":"25c79b89-329b-4-
80936045","component":"Authentication","eventName":"AM-LOGIN-COMPLETED","result":"FAILED","entries":[{"moduleId":"LDAP","info":{"failureReason":"INVALID_PASSWORD","ipAddress":"","authLevel":"0"}}],"userId":"[email protected],ou=user,o=APP,ou=services,dc=openam,dc=DC,dc=com","principal":["@gmail.com"],"timestamp":"2019-07-18T10:16:16.941Z","trackingIds":["13eb1756f23f3a6302"],"_id":"b-0f75fd67a3ae-80936049"}

Tags (1)
0 Karma
1 Solution

vishaltaneja070
Motivator

You can do it like this:
you have to use transform to change the sourcetype like below:
props:

[source::/opt/app/logs/openam/authentication.audit.json]
TRANSFORMS-changesourcetype = newsourcetype

transforms:
[newsourcetype]
REGEX = .
DEST_KEY = MetaData:Sourcetype
FORMAT = sourcetype::Forgerock

View solution in original post

0 Karma

vishaltaneja070
Motivator

You can do it like this:
you have to use transform to change the sourcetype like below:
props:

[source::/opt/app/logs/openam/authentication.audit.json]
TRANSFORMS-changesourcetype = newsourcetype

transforms:
[newsourcetype]
REGEX = .
DEST_KEY = MetaData:Sourcetype
FORMAT = sourcetype::Forgerock

0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

Make your Splunk investment work harder with Optimization Advisor

Value Insights brings usage evidence and practical recommendations together to help customers make more ...

How Splunk AI Assistant Is Transforming Investigations: Insights from .conf26

At .conf26 in Denver, I spent much of my time in conversation with Splunk customers about Splunk AI Assistant. ...

Make Your Machine Data AI-Ready in Splunk

Every team is getting ready for AI agents.   Thursday, November 12, 2026  |  11AM  PST / 2PM EST   ...