Created
February 12, 2019 18:08
-
-
Save rkreddyp/10f1c889c4719ad66a86f0deb3725bae to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
eventdf = oeventdf.copy() | |
print (eventdf.columns) | |
eventdf.userIdentity= eventdf.userIdentity.astype(str) | |
eventdf = eventdf [eventdf.userIdentity.str.contains("Root")] | |
eventdf = eventdf [['EventSource', 'EventName', 'Username', 'EventTime', 'sourceIPAddress']] | |
eventdf = eventdf.groupby( ['EventTime', "EventSource","Username", 'sourceIPAddress'] )['EventName'].agg(','.join).reset_index(name='Eventnames') | |
sdf.to_csv("/tmp/rootactivity.csv") | |
link = lib_helpers.take_uploadfilename_return_link("rootactivity.csv", "rootactivity.csv") | |
display (md("##### Download the csv of the below table [here]({link})".format(link=link) ) ) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment