Skip to content
This repository has been archived by the owner on Dec 11, 2023. It is now read-only.

Commit

Permalink
add comments to code example
Browse files Browse the repository at this point in the history
  • Loading branch information
isaisabel committed Dec 21, 2020
1 parent 928e488 commit 6347904
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions attackToExcel/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,11 @@ Example of accessing [Pandas](https://pandas.pydata.org/) DataFrames:
import attackToExcel
import stixToDf

# download and parse ATT&CK STIX data
attackdata = attackToExcel.get_data_from_version("enterprise-attack")
techniques_data = stixToDf.techniquesToDf(attackdata, "enterprise-attack")

# show T1102 and sub-techniques of T1102
techniques_df = techniques_data["techniques"]
print(techniques_df[techniques_df["ID"].str.contains("T1102")]["name"])
# 512 Web Service
Expand All @@ -44,6 +46,7 @@ print(techniques_df[techniques_df["ID"].str.contains("T1102")]["name"])
# 323 Web Service: One-Way Communication
# Name: name, dtype: object

# show citation data for LOLBAS Wmic reference
citations_df = techniques_data["citations"]
print(citations_df[citations_df["reference"].str.contains("LOLBAS Wmic")])
# reference citation url
Expand Down

0 comments on commit 6347904

Please sign in to comment.