Posts Tagged ‘dsp decrypt program’
Encrypted Programming Protects the Factory, Not the Product
A brand owner who sends a plaintext image to a contract manufacturer has given that manufacturer the product. Encrypting the file is the response, and it is a reasonable one, but it is important to be clear about what it achieves.
It does not make the image unreadable to the manufacturer, because the manufacturer has to program it. It makes the image unreadable to anyone who does not have the key, and it makes a leak attributable to whoever held the key. The second property is the one that matters commercially.
What the arrangement looks like
The brand owner encrypts the image and sends the ciphertext. The manufacturer’s programmer holds the key, decrypts in hardware, and burns the device. The plaintext exists inside the programmer for the duration of the operation.
| Party | Holds | Can produce the image |
|---|---|---|
| Brand owner | The plaintext and the key | Yes |
| Manufacturer | The ciphertext and the key | Yes, transiently |
| Manufacturer’s staff | The key, if the equipment allows | Depends on the implementation |
| Anyone else | The ciphertext | No |
The third row is where the control either works or does not. If the key is inside a sealed programmer that never exposes it, a technician cannot produce the image even with full access to the equipment. If the key is a file on the programming PC, the technician can.
Three implementations and their weaknesses
The security of the arrangement is entirely in how the key is held, and three implementations appear in practice.
The key embedded in the programmer’s firmware is the most common and the weakest. The programmer decrypts internally, so the key never appears on the PC, which is the point. The weakness is that the key is in a firmware image on a flash chip inside the unit, and that chip is readable.
| Implementation | Key location | Weakness |
|---|---|---|
| Embedded in the programmer firmware | Internal flash | Extractable by reading the unit |
| On a dongle | A separate USB device | Extractable, and clonable |
| Per-programmer key with a server | A server, released per job | Depends on the server’s security |
| In a secure element in the programmer | A protected die | Strongest; extraction requires silicon work |
The first row is defeated by the same technique as any other embedded device, and the work is described in the programmer as an asset. A programmer is a small embedded system with a flash chip and a plastic case, and it is not designed to resist someone who opens it.
The third row is the strongest practical design and it moves the problem to the network. A programmer that must obtain a key per job, over an authenticated connection, with a job count, is a programmer whose compromise is bounded by what it can request.
Why the cryptography is not the weak point
The cipher is fine. A standard block cipher in a standard mode is not going to be broken, and the choice of mode matters only for how much ciphertext an attacker can collect.
The weakness is that the plaintext must exist somewhere in the clear, and the place it exists is the place that programs the device. Any measure that puts the plaintext on the manufacturing floor is a measure whose security is physical.
| Layer | Strength | Where it fails |
|---|---|---|
| Cipher | Strong | Not the problem |
| Key storage | Varies | The actual weakness |
| Key release policy | Varies | The actual weakness |
| Physical control of the line | Varies | The actual weakness |
| Contractual terms | Strong, if enforced | Detection rather than prevention |
The fifth row is the one that gives the arrangement its real value. A manufacturer who leaks an image that was sent in ciphertext, under a contract that names the key holder, is a manufacturer who can be identified. That is worth more in practice than a marginal improvement in cryptographic strength.
What a customer should ask
Four questions establish whether the arrangement does what it is supposed to.
Does the manufacturer ever see the key in a form they can copy? This is the question that distinguishes a sealed programmer from a PC application with a key file.
| Question | Good answer | Bad answer |
|---|---|---|
| Is the key ever visible to staff? | No, sealed unit | Yes, a file on the PC |
| Can a unit be used after it is retired? | Keys revoked | Unit retains the key |
| Is each job authorised? | Per-job release | One key, unlimited use |
| Is the file bound to a product? | Product identifier in the header | Any file works |
The fourth row is the one that prevents a subtler problem. A programmer that accepts any correctly encrypted file will program a competitor’s image if one is supplied, and a manufacturer who is asked to run an extra batch has no way to know which product it belongs to.
Recovering an image from this arrangement
The recovery route follows from the three implementations.
Where the key is in the programmer’s firmware, the image is recoverable by reading the programmer: the key comes out with it, and the ciphertext is already in hand. That is not an attack on the cryptography; it is an attack on the storage.
| Implementation | Route to the image |
|---|---|
| Key in programmer firmware | Read the programmer, then decrypt |
| Key on a dongle | Read the dongle |
| Per-job key from a server | Capture the key at release, or attack the server |
| Key in a secure element | Silicon attack, or capture the plaintext |
The fourth row leads back to the manufacturing floor. If the key cannot be extracted, the plaintext still exists in the programmer’s memory during a job, and a probe on the right bus during a programming operation captures it — which is the same class of measurement as reading a memory bus.
What the review produces
The deliverable is a key-flow diagram with four annotations: where the key lives, who can obtain it, what a person with physical access would recover, and what a leak would be attributable to.
That last item is the one that justifies the arrangement. A diagram that shows the key inside a sealed unit, released per job, with a record of which job used it, describes a scheme where a leaked image can be traced to a specific batch and a specific operator. A diagram that shows a key file on a shared drive describes a scheme where a leak is untraceable, and untraceable leaks are the ones that turn into a competitor’s product.
| Finding | Recommendation |
|---|---|
| Key on a PC filesystem | A sealed programmer with per-job release |
| One key for all products | Per-product keys in the header |
| Units retain keys after retirement | A revocation and decommissioning process |
| No job record | A release log tied to the file hash |
The honest limitation
Encrypted programming does not make a product confidential on a manufacturing floor. It makes a leak attributable, and it raises the effort required for a casual one.
A customer who is told this and still chooses the arrangement has made an informed decision, and the arrangement is then worth having: it deters the opportunistic copy and it provides a path to recourse. A customer who believes the arrangement makes the image unreadable will not apply the other controls, and those controls are the ones that matter.
| Belief | Actual protection |
|---|---|
| Encrypted file means the factory cannot read it | It can, in the programmer |
| The key cannot be extracted | It can, from the equipment |
| The arrangement is sufficient alone | It is one layer of four |
The four layers — contract, process, equipment and silicon — are set out in supply chain leaks. The silicon layer that backstops them is the read protection in three protection layers, and its effectiveness on a device that has already been programmed is the question answered by the attack surface map.
What we deliver for this class of request is a review of the key handling: where the key lives, who can obtain it, and what a person with access to the equipment would recover. Where the finding is that the key is extractable, the practical recommendation is usually a sealed programmer with per-job authorisation rather than a stronger cipher.