Custom Plugin Packages for NASL and CA Certificate Upload

Note: Tenable does not support troubleshooting custom plugin packages for NASL.

Note: Linked Tenable Nessus scanners do not support custom plugins. Custom plugins are only supported on active (managed) scanners. For more information, see Linked Scanning Overview.

You can upload a custom plugin package as a .tar.gz or .tgz file. Depending on your needs, you must include a combination of the following files:

  • A custom_feed_info.inc file. Always include this file to time stamp your upload to Tenable Security Center Director.

  • (Optional) A custom_nasl_archive.tar.gz or custom_nasl_archive.tgz file. Include this file if you are uploading one or more custom plugins.

  • (Optional) A custom_CA.inc file. Include this file if you are uploading one or more CA certificates to solve a Tenable Nessus scanning issue.

After you Manage Custom Plugin Packages, Tenable Security Center Director pushes the package to Tenable Nessus for use when scanning.

Note: The system untars the files within your custom plugin package and overwrites any identically named files already in Tenable Security Center Director or Tenable Nessus. The exception is the custom_CA.inc file, which the system merges with the existing CA certificates. For more information, see custom_CA.inc Guidelines.

custom_feed_info.inc Guidelines

Always include this file to time stamp your upload to Tenable Security Center Director. This text file must contain the following lines:

PLUGIN_SET = "YYYYMMDDHHMM";

PLUGIN_FEED = "Custom";

The PLUGIN_SET variable YYYYMMDDHHMM is the date and time 2 minutes in the future from when you plan to upload the file to Tenable Security Center Director.

custom_nasl_archive.tar.gz or custom_nasl_archive.tgz Guidelines

Include this file if you are uploading one or more custom plugins. This package must contain one or more custom plugin NASL files.

All custom plugins must have unique Plugin ID numbers and have family associations based on existing Tenable Security Center families.

Note: Tenable Support does not assist with creating custom plugin NASL files.

custom_CA.inc Guidelines

Include this file if you are uploading one or more CA certificates to solve a Tenable Nessus scanning issue. This text file must contain PEM-encoded (Base64) CA certificate text.

For troubleshooting information, see Troubleshooting Issues with the custom_CA.inc File.

One CA Certificate

If you need to include a single CA certificate, paste the PEM-encoded (Base64) certificate directly into the file.

-----BEGIN CERTIFICATE-----

certificatetext

certificatetext

certificatetext

certificatetext

-----END CERTIFICATE-----

Multiple CA Certificates

If you need to include two or more CA certificates, include the PEM-encoded (Base64) certificates back-to-back.

-----BEGIN CERTIFICATE-----

certificate1text

certificate1text

certificate1text

certificate1text

-----END CERTIFICATE-----

-----BEGIN CERTIFICATE-----

certificate2text

certificate2text

certificate2text

certificate2text

-----END CERTIFICATE-----

How Uploads Affect Existing CA Certificates

When you upload a custom plugin package that includes a custom_CA.inc file, Tenable Security Center Director adds the CA certificates in the uploaded file to the CA certificates that are already stored. The upload does not replace the existing certificates. For example, if you previously uploaded three certificates and then upload a package that contains two new certificates, Tenable Security Center Director stores all five.

  • If a certificate appears in both the existing and the uploaded file, Tenable Security Center Director stores it only once. Tenable Security Center Director recognizes duplicate certificates even if their line endings or whitespace differ.

  • The order of the certificates in the file does not matter.

  • If you have not uploaded a custom_CA.inc file before, Tenable Security Center Director uses the uploaded file as is.

  • Tenable Security Center Director applies the merge only if the upload succeeds. If a custom plugin in the package fails validation, Tenable Security Center Director does not apply the package and keeps your existing CA certificates.

Tenable Security Center Director records each merge in the administrator log. For example: Merged CA bundle: 3 existing + 2 new = 5 total certificates.

Reset the CA Certificate Bundle

To remove all previously stored CA certificates and replace them with only the certificates in your new custom_CA.inc file, include an empty .sc_reset_ca file in your custom plugin package.

To reset the CA certificate bundle:

  1. In the command line interface (CLI), create an empty file named .sc_reset_ca:

    # touch .sc_reset_ca

  2. Prepare a new custom_CA.inc file that contains only the CA certificates you want to keep.

  3. Tar and compress the files together, including .sc_reset_ca in the root of the package. For example:

    # tar -zcvf upload_this.tar.gz custom_feed_info.inc custom_CA.inc .sc_reset_ca

  4. Upload the package, as described in Upload the Custom Plugin Package.

    Tenable Security Center Director skips the merge, replaces the stored CA certificates with the certificates in the uploaded custom_CA.inc file, and removes the .sc_reset_ca file. Tenable Security Center Director records the reset in the administrator log: Custom CA bundle reset - replaced with new bundle.

Note: A reset removes every CA certificate that you uploaded previously. Include all the certificates that you still need in the new custom_CA.inc file.