Tiza Group

Home / Guides / Testing, commissioning and faults

Configuration File Rejected by Digital Signature

Configuration file rejected by digital signature: causes by likelihood, how to separate integrity from trust and what to fix. We configure it remotely.

By Shadai García, CEO and protection engineer at Tiza Group.

Short answer

A signed configuration file is rejected when the signature no longer matches its content (someone edited it after signing), when the signer's certificate is not recognized, expired or revoked, or when the device or tool does not expect that format. Integrity and trust are two different questions: the first is fixed by going back to the original file or signing again; the second, with the certificate chain.

Symptom

You try to load a configuration file (for example, a communications or engineering file in SCL format) into an IED, or to open it in a tool that requires a signature, and the system answers with a rejection: invalid signature, integrity not verified, unknown origin or untrusted certificate. The file does not load, or it loads with a warning and is not applied.

The exact message varies between manufacturers, but it is almost always one of two different failures: integrity (the content changed after signing) or trust (the content is the original, but the device does not recognize the signer). What protects an SCL document and how it is signed is covered in the SCL file security guide. This guide is limited to diagnosing a rejection.

Likely causes, from most to least likely

#CauseHow to recognize it
1The file was modified after signingThe rejection occurs with an edited copy; the original is accepted
2Unintended change by tools, email or transferDifferences in encoding, line endings or spaces between the original and the copy
3The signer’s certificate is not in the device’s trust listMessage about unknown origin or issuer; the file is intact
4Certificate expired, not yet valid or revokedThe certificate dates do not cover the moment of loading
5Wrong clock on the device or the toolA valid certificate is rejected as expired; the device date is wrong
6Incomplete certificate chainThe intermediate certificate of the issuing authority is missing
7Signature algorithm or format the device does not supportImmediate rejection with a file that other devices accept
8File or firmware version different from the expected oneThe rejection changes when another version is loaded

How to diagnose it

  1. Test the original. Load the file exactly as it came from whoever signed it. If the original is accepted, the problem is the copy (causes 1 and 2). If it is also rejected, look at trust and validity.
  2. Compare byte by byte. Calculate a checksum (hash) of the original and of the copy. If they differ, something changed the content; check which tool touched it.
  3. Identify the signer. Read the signing certificate from the file: issuer, holder, validity dates. Compare them with what the device has installed as trusted.
  4. Check validity and date. Verify the date and time of the device and of the tool before concluding that the certificate expired.
  5. Check the chain. Confirm that the certificate of the issuing authority (and the intermediate ones) is installed on the device.
  6. Read the log. The device security or event log usually gives the exact reason; use it to decide between integrity, trust or format.
  7. Compare with another device. If another device of the same model accepts the file, the problem is in the trust configuration of the first one.

Illustrative example

A generic situation. An engineer receives a signed file, opens it in an editor “just to review” and saves it. The editor changes the line endings. The device rejects it as invalid. The hash of the original and that of the copy do not match. The copy is discarded, the original is used again and the device accepts it. It is then agreed that every review is done on a read-only copy and that the signed original is not opened again in an editor.

Field checklist

  • The original file was tested, without passing through any editor.
  • The hash of the copy matches that of the original.
  • The signer’s certificate is valid and not revoked.
  • The date and time of the device are correct.
  • The certificate of the issuing authority is installed on the device.
  • The signature format and algorithm are the ones the device supports.
  • The file version matches the firmware.
  • The reason for the rejection and its correction were recorded.

What to do

  • Broken integrity: go back to the signed original. If the change was necessary, make it in the source file and sign again with the authorized certificate.
  • Unknown certificate: install the issuing authority or the signer’s certificate in the trust list, following the device procedure and with approval from whoever administers security.
  • Expired or revoked certificate: request a new one from the issuing authority. For certificate management, see Public key infrastructure in substations and X.509 certificate and CSR request for IEDs.
  • Clock: correct the device time synchronization before touching certificates.
  • Format or version: confirm with the manufacturer what is supported and redo the export.

Integrity and trust: two different questions

Answer them separately. Is the content the same as what was signed? This is answered with the hash and with the signature verification on the original. Does the device trust whoever signed? This is answered with the installed certificate chain and its dates. A rejection for integrity is corrected by going back to the original; one for trust is corrected on the device or with another certificate, and is never fixed by editing the file. Mixing the two questions is the most common source of lost time: the file is changed when the problem was the certificate, or a certificate is installed when the file had been altered. Keep with the signed file its hash, the signer’s certificate and the signing date, so that you can prove origin and integrity later.

What not to do

  • Do not disable signature verification on a device in service just to make the file load.
  • Do not sign with a certificate that is not authorized and do not share the private signing key.
  • Do not edit a signed file by hand “to fix a detail”.
  • Do not load a configuration into an energized device without a backup of the previous one and without agreement from operations.
  • Do not send private keys by email or store them next to the file.

When to call us

If the file keeps being rejected, or you need to organize the signing and certificate workflow of your engineering, we review the file, the chain of trust and the device configuration. We configure it remotely. Write to us.

References

  • IEC 62351-11, Power systems management and associated information exchange – Data and communications security – Part 11: Security for XML documents.
  • IEC 61850-6, Substation configuration description language (SCL).
  • IEC 62351-9, cryptographic key management for power systems.
  • W3C recommendations on XML digital signatures.

Frequently asked questions

Why does the device reject a file I did not modify?

Because any change of bytes invalidates the signature, even one you do not consider an edit: an editor that rewrites line endings or encoding, an export that reorders elements, an email or a file system that alters the text. It can also be a trust problem and not a content problem: the signer's certificate is not in the device's trust list.

Can I remove the signature so the file is accepted?

Only if the installation's security policy allows it and it is recorded. Removing the signature eliminates the guarantee of origin and integrity that was being sought. It is better to find out why it fails and sign again with the authorized certificate.

Does an expired certificate invalidate a file's signature?

It depends on how the device validates: some check validity at the time of loading and others only the chain of trust. Check the device date and the manufacturer's validation rules, because a wrongly set clock can also make a valid certificate look expired.

WhatsApp