CSV
  • 25 Apr 2023
  • 11 Minutes to read
  • Dark
    Light
  • PDF

CSV

  • Dark
    Light
  • PDF

Article Summary

The CSV adapter imports .csv files with inventory information including devices and serial numbers, users, and installed software data.

NOTE

The CSV adapter parameters and functionality are common to all adapters that import files:

Parameters

  1. File contains users information

    • Selecting this option will import the file as a list of Users instead of devices.
    • See the below section for fields required in a Users Information File.
  2. File contains installed software information

    • Selecting this option will import an installed software list instead of devices.
    • See the below section for fields required in a Software Applications File.
  3. File name (required) - A unique name for the adapter connection. The value supplied here will be populated in the File name field for the data supplied by a specfic adapter connection.

    Note:

    The specified File Name doesn't need to be the actual imported file name. This field is an identifier for use in the Query Wizard.

  4. Upload file (optional) - Select a local CSV file to import.

    Note:
    • When using this option, the data imported from the CSV will never be fetched again, as the file is static.
    • Each adapter that imports files supports a different file type: CSV, JSON or XML.
  5. Path to Resource (SMB/URL) (optional) - Specify an SMB share path, a HTTP(S) URL or an FTP URL where a file can be fetched for this connection.

    NOTE

    If you are uploading a file from an online storage location and you want to use this file only for custom enrichment, you must disable the Active Connection setting on the CSV adapter connection.

    DisableActiveConnection-cut.png

    • This path must include the file name.
    • If an SMB share path is supplied:
      • The path must start with double-backslashes ("\\").
      • If Suppress NetBIOS name lookup is enabled, the path must include the server's full NetBIOS name (in the following format: \\<full_server_NetBIOS_name>\path\to\file.ext).
    • If a HTTP(S) URL is supplied:
      • The endpoint must support the HTTP GET method.
      • All URLs must start with HTTP:// or with HTTPS://.
    • If an FTP URL is supplied, all URLs must start with FTP:// or with SFTP:// or with FTPS://
      • The default port for each method is as follows:
        • FTP: 21
        • SFTP: 22
        • FTPS: 990
      • A custom port can be specified in the supplied path, for example: ftps://my.host.in.axonius.com:21/path/to/file.ext
  6. User name for online resource (Share/URL) and Password for online resource (Share/URL) (optional) - Optional user name and password for the SMB share or the URL. These settings may be required if the "ubuntu" user on the Axonius system does not have access to the SMB share / URL.

    • If supplied for an SMB path, the user name and the password will be used for authentication for this connection.
    • If supplied for a URL, the user name and the password will be used for BASIC authentication for this connection.
  7. Azure Storage Container Name - The name of the container on Azure where the CSV file is located.

  8. Azure Connection String - The connection string that includes the authorization information required to access data in the Azure Storage account.

    • When you Configure the CSV adapter to fetch a file from Azure you need to supply the following information, the File Name, the Azure Storage Container Name, the Azure Blob Name, and the Azure Connection String. You can find the connection string in the Azure portal under Storage Accounts -> [Account Name] -> Access Keys, where [Account Name] is the specific storage account that contains the CSV files to be ingested into Axonius. You will need to copy the entire connection string and paste it into this field.
  9. Azure Blob Name - The Azure Blob Name.

  10. Amazon S3 bucket name (optional) - The name of the S3 bucket to fetch the file.

  11. Amazon S3 object location (optional) - The location within the S3 bucket where the file can be fetched.

  12. Amazon S3 Use EC2 Attached Instance Profile

    • If enabled, Axonius will use the EC2 instance (Axonius installed on) attached IAM role / instance profile.
    • If disabled, Axonius will use the supplied account details in the AWS Access Key ID and AWS Access Key Secret.
  13. Amazon S3 Access Key ID and Amazon S3 Secret Access Key (optional) - The credentials used to access the S3 object.

  14. Encoding (optional) - Specify a specific file encoding or let Axonius encode it.

    • If supplied Axonius will try to encode the CSV file based on the specified the file encoding type (for example, utf-8) for this connection.
    • If not supplied, Axonius will try to encode the CSV file based on common file encoding types for this connection.
  15. Ignore illegal characters - Select whether illegal characters are ignored during the data import. An illegal character is any character that cannot be translated in the specified file encoding.

    • If enabled, Axonius will ignore illegal characters and will omit those from the imported data.
    • If disabled, if an illegal character is found, the entire data import will fail.
  16. Custom prefix for dynamic fields (optional) - Specify a prefix to be added for dynamic fields. Dynamic fields refer to any field that is not part of an asset default fields.

    • If supplied, Axonius will add the specified prefix for any dynamic field. This can assist you in identifying such fields.
    • If not supplied, Axonius will not add any prefix for any dynamic field.
  17. Multi-value fields delimiter (optional) - Specify a delimiter to separate between values within the same field in the imported CSV file.

    • If supplied, Axonius will consider fields that contains the specified delimiter as multi-value fields. For example, ';'.
    • If not supplied, Axonius will consider all imported fields as single-value field.
  18. Verify SSL - If HTTP(S) URL is specified, verify the SSL certificate offered by the host supplied in the Path to Resource (SMB/URL) field. For more details, see SSL Trust & CA Settings.

  19. HTTP proxy (optional) - A proxy to use when connecting to a HTTP(S) URL specified in Path to Resource (SMB/URL).

  20. HTTPS proxy (optional) - A proxy to use when connecting to a HTTP(S) URL specified in Path to Resource (SMB/URL).

  21. Additional HTTP headers (optional) - Specify additional information to pass with the HTTP request.

    • If supplied Axonius will pass additional information with the HTTP request (for example, {"Accept": "text/csv"}) for this connection.
    • If not supplied, Axonius will not pass additional information with the HTTP request for this connection.
  22. Suppress NetBIOS name lookup - Applicable only for files fetched from SMB share.

    • If enabled and if the file is fetched from SMB share, Axonius will not verify the server's name via NetBios for this connection.
    • If disabled and if the file is fetched from SMB share, Axonius will verify the server's name via NetBios for this connection.
  23. For details on the common adapter connection parameters and buttons, see Adding a New Adapter Connection.

CSV adapter

Advanced Settings

Note:

From Version 4.6, Advanced settings can either apply for all connections for this adapter, or you can set different advanced settings and/or different scheduling for a specific connection, refer to ​Advanced Configuration for Adapters.

  • Set Time Zone - Set the time zone of date fields fetched with this adapter. Default is UTC.

If multiple file options are added to a 'file-based' adapter, what file will be imported?

If multiple import file import types are provided in the CSV adapter (or for other file-based) adapter, the following order will be taken for importing:

  1. Path to resource (SMB/URL)
  2. Amazon S3 Bucket
  3. Uploaded file


The file content is determined based on the following order:

  1. User assets - If File contains users information is selected
  2. Installed software list - If File contains installed software information field is enabled.
  3. Device assets - If none of the options above is selected, the CSV is assumed to be a device CSV. If a device exists more than once in a CSV file, only the first device found is used.

Which fields are required for each Import Type?


Import Type*KEY fieldsOptional fields
From a File- File name
- Upload file
- File contains users information
- File contains installed software information
- Encoding
- Ignore illegal characters
- Custom prefix for dynamic fields
- Multi-value fields delimiter
- Connection Label
From a URL- File name
- Path to resource (SMB/URL)
- Verify SSL
- Choose Instance (on multi-node Axonius environment)
- File contains users information
- File contains installed software information
- Username for online resource (Share/URL)
- Password for online resource (Share/URL)
- Encoding
- HTTP proxy
- HTTP proxy
- HTTPS proxy
- Additional HTTP headers
- Ignore illegal characters
- Custom prefix for dynamic fields
- Multi-value fields delimiter
- Connection Label
From a file share- File name
- Path to resource (SMB/URL)
- Verify SSL
- Choose Instance (on multi-node Axonius environment)
- Suppress NetBIOS name lookup
- File contains users information
- File contains installed software information
- Username for online resource (Share/URL)
- Password for online resource (Share/URL)
- Encoding
- HTTP proxy
- HTTP proxy
- HTTPS proxy
- Additional HTTP headers
- Ignore illegal characters
- Custom prefix for dynamic fields
- Multi-value fields delimiter
- Connection Label
From an Amazon S3 Bucket- File name
- Amazon S3 bucket name
- Amazon S3 object location (key)

- File contains users information
- File contains installed software information
- Amazon S3 Access Key ID
- Amazon S3 Secret Access Key
- Encoding
- Ignore illegal characters
- Custom prefix for dynamic fields
- Multi-value fields delimiter
- Connection Label

Note:
Based on the order of operations, any fields that are specified and not applicable to the import type will be ignored. For example, filling in the Amazon S3 bucket name field while the Path to resource (SMB/URL) is populated will cause the Path to resource (SMB/URL) property to be ignored but not removed.

Which fields will be imported with a devices file?

The following data will be imported as common data fields while any other data in the CSV/JSON/XML will exclusively be Adapter Specific data.

NOTE
Fields marked as *KEY indicate that at least one of those values is required to import. The more fields available will help provide stronger correlation.
UI Field NameAccepted CSV Field Name(s)Notes
Architecturearchitecture
Asset Namename, vmname, displayname, assetname, machinename, instancename, samaccountname, endpointnameIf no hostname is configured, the Asset Name value will be used for the Host Name.
Device Manufacturer Serialserial, serialnumber, sn, hostserialnumber, deviceserialnumber, serial#, endpointserialnumber*KEY
Device Manufacturermanufacturer, devicemanufacturer
Device Modelmodel, modelid, endpointmodel
Domaindomain, domainname, endpointdomainIf this value is not specified AND the device is specified in DOMAIN\Name format, Axonius will replace the Domain value with the parsed out DOMAIN.
Host Namehostname, host, fqdn, fullyqualifieddomainname, compname, computername, servername, dnsname, hosthostname, endpointfqdn*KEY If the device is specified in DOMAIN\Name, Axonius will parse the DOMAIN value out. If the CSV field is set to "unknown", Axonius will set the Host Name to blank.
IDid, identifier, serialnumber, assetid, resourceid*KEY The ID field is a combination of the "CSV File Name" value and the specified field names.
IPsipaddresstext, ip, ipaddress, ipaddresses, ips, primaryip, endpointipaddressThis field will accept a comma separated set of IP addresses.
Last Seenlastmessagetime, lastdiscoveredtime, lastseenIf this value is not specified, we will enter the time that the CSV was last imported.
Last Used UsersusernameThis will append to the existing Last Used Users list if the device already exists.
MACmac, macaddress, macaddresses, macs*KEY This field will accept a comma separated set of MAC addresses.
Network InterfacesnetworkinterfacesAxonius will attempt to parse IP address(es), MAC address(es), and network interface cards from this field.
OS (see Notes)os, osname, osversion, operatingsystem, osmode, uname, endpointosThis field will be parsed out into multiple properties within the OS field. Not all OSes will be parsed properly. Please reach out to Axonius if an OS is not parsing as expected.
OS: Kernel Versionkernel, kernelversion
Software NamepackagesThis is delimited by spaces.

Which fields will be imported with a users file?

The following data will be imported as common data fields while any other data in the CSV/JSON will exclusively be Adapter Specific data.

Note:
Fields marked as *KEY indicate that at least one of those values is required to import. The more fields available will help provide stronger correlation.
UI Field NameAccepted CSV Field Name(s)Notes
Domaindomain, domainname, endpointdomain
First Namefirstname, givenname
IDid, identifier, serialnumber, assetid, resourceid*KEY The ID field is a combination of the "CSV File Name" value and the specified field names.
Last Namelastname, surname, sn
Mailmail, email, usermail, mailaddress, email address, emailprimarywork*KEY
Namename, vmname, displayname, assetname, machinename, instancename, samaccountname, endpointname*KEY
User Nameusername*KEY

Which fields will be imported with a software applications file?

The following data will be imported as common data fields while any other data in the CSV/JSON will exclusively be Adapter Specific data.

NOTE
Fields marked as *KEY indicate that at least one of those values is required to import. The more fields available will help provide stronger correlation.
UI Field NameAccepted CSV Field Name(s)Notes
Host Namehostname, host, fqdn, fullyqualifieddomainname, compname, computername, servername, dnsname, hosthostname, endpointfqdn*KEY This field is required since the software list is imported to each individual device.
Software Namesoftwarename, swname*KEY
Software Pathsoftwarepath, swpath
Software Vendorsoftwarevendor, swvendor
Software Versionsoftwareversion, swversion
CVE IDIf present, a row featuring a CVE ID will be parsed as vulnerable software in addition to installed software. The following fields will also be parsed, if possible:
CVE Description
CVE Severity'NONE', 'LOW', 'MEDIUM', 'MODERATE', 'SEVERE', 'SERIOUS', 'HIGH', 'CRITICAL', 'URGENT', 'INFO', 'UNTRIAGED', 'NEGLIGIBLE'An invalid CVE Severity value is ignored.
CVE Status'open', 'closed', 'reopen', 'expired', 'done', 'valid', 'obsolete', 'pending'An invalid CVE Status value is ignored.

Example CSV File

For an example of a csv file, download the following zipped csv:

CSVExamples.zip


Changing your password will log you out immediately. Use the new password to log back in.
First name must have atleast 2 characters. Numbers and special characters are not allowed.
Last name must have atleast 1 characters. Numbers and special characters are not allowed.
Enter a valid email
Enter a valid password
Your profile has been successfully updated.