Custom Sandfly Operation
Custom sandflies can be cloned to enhance the system sandflies or create entirely new methods of security analysis that may be unique to your operational environment or use cases. Either way, they leverage the file, directory, log, process, user or other incident response analysis methods that the Sandfly system has to offer.
In general, "sandflies" are small JSON modules that are passed to the Sandfly agentless forensic engines to investigate remote systems. They also use regular expression🡵 (aka regex) in the options section of the JSON. Thus, regex knowledge is valuable, especially for creating or modifying complex rules.
Viewing
To see an unfiltered list of every sandfly that is available on the server, in the sidebar menu, select Tuning > Sandflies. Use the Presets button in the table's toolbar to quickly filter on commonly used views, including Custom Only. Select sandflies with their checkboxes to show the bulk actions bar, with Scan, Activate, Deactivate, and Delete for the selected sandflies.
Adding
Depending on whether an existing sandfly or template is being reused or an entirely new one is being created from scratch, the web interface provides two ways to individually add a custom sandfly.
- Use the Clone button in the Actions column of the Sandflies page or on any sandfly's Details page.
- This method copies the corresponding JSON and adds it into the Creating sandfly form.
- In order to save it, at minimum the value for
namemust be changed to something unique.
- Use the option to add a sandfly on the Sandflies page toolbar.
- This method comes populated with example JSON which can be extended or replaced entirely.
Please refer to the Custom Sandfly Creation documentation for further details for defining custom Sandflies.
Bulk Administration
Downloading
Custom sandflies can be downloaded all at once via the web interface from the Download button found in the Sandflies page toolbar. Using that button will create a single, bulk-formatted JSON file which contains every custom sandfly that is on your server.
Uploading
Custom sandflies can also be uploaded in bulk via a web browser from the Upload option found in the Sandflies page toolbar. The upload form requires a single, bulk-formatted JSON file, regardless of whether it contains one or multiple custom sandflies.
A bulk-formatted file contains each sandfly individually encapsulated by an outer JSON bulk structure. An intact file can only be used for the bulk upload / download operations and not as the individual JSON that is used with custom sandflies. However, individual sandfly JSON can be extracted from that file.
CAUTION: Bulk JSON files are structured differently than custom sandfly JSONA bulk JSON file contains an outer wrapper that is used for the bulk upload and download operations, even when it contains only a single custom sandfly. The JSON of an individual custom sandfly does not have this wrapper.
Malformed JSON and custom sandflies with a name of an existing system sandfly will be rejected. Uploading files that contain custom sandfly names that already exist will completely overwrite those sandflies. Names that do not exist at the time of the upload will create new custom sandflies.
Updated 6 days ago