From a7b885328d54b80cac6aa318e14ceea3ed53d940 Mon Sep 17 00:00:00 2001 From: Scott Kuffer Date: Thu, 3 Jun 2021 09:09:38 -0400 Subject: [PATCH] Added better instructions for how to use the plugins library --- README.md | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 2502513..b0549dc 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,25 @@ This repo is for the community to contribute any custom parsers for scan tools w An example parser has been uploaded into the Whitesource folder to parse Whitesource xml output into a Nucleus csv format. Feel free to use this template as a future parsing script, or feel free to completely chop it up. -For examples of custom csv, xml, or json files that Nucleus supports, refer to the Nucleus docs at support.nucleussec.com. +For examples of custom csv, xml, or json files that Nucleus supports, refer to the Nucleus docs at https://help.nucleussec.com/docs/custom-scans. You will get credit for your parsers that you upload. If you have created a custom parser for Nucleus, please submit a pull request! We will reach out to you with any questions we have/tests etc. +Instructions for use: +1. Install python 3.6 or higher +2. Open the command line +3. Install python requests library `pip install requests` (note you may need to upgrade pip if you just installed python) +4. Find the output file you would like to convert to Nucleus format and copy it to somewhere you can easily access it +5. Navigate in the cli to one of the directories where the plugins are located +6. OPTIONAL: If you want to automatically POST the output file to your Nucleus account, you will need to update 2 variables at the top of the python script +-- NUCLEUS_ROOT_URL = the root url (without trailing slash) to your Nucleus instance (ie which url do you go to log into the Nucleus UI) +-- API_KEY = The API key you generate in the Nucleus UI to be able to programmatically access your Nucleus account. NOTE: you can also create an API-only account and use this api key +7. Run the script using standard python cli commands + +Standard flags for Nucleus plugins: +-i --inputfile This is the relative or absolute path to the file you wish to convert. Include the file format (eg ../../files/nucleus/crowdstrike_output.csv). REQUIRED +-o --outputfile This is the relative or absolute path to the file which will be outputted from the script (eg ../../files/nucleus/crowdstrike_converted_to_nucleus_format.csv) REQUIRED +-# --project_id This is the id of the Nucleus project you are going to upload the output file to. When this flag is set, the script will automatically try to POST the output file to Nucleus. You can find this on the "Global Dashboard" page in the Nucleus UI. OPTIONAL + +Unique Flags: +Some plugins have unique flags depending on their output. You can find these by just running the command `` where parser_name is the name of the plugin you want to run. \ No newline at end of file