ownership and control of firmware in open compute project...

28

Upload: others

Post on 19-Jul-2020

2 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute
Page 2: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

Ownership and Control of Firmware in Open Compute Project (OCP) Devices

Elaine Palmer, Senior Technical Staff Member, IBM Thomas J. Watson Research

Tamas Visegrady, Research Staff Member, IBM Research - Zurich

Michael Osborne, Research Staff Member, IBM Research - Zurich

[OSF/Security]

Page 3: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

Ownership and Control of Firmware in Open Compute Project (OCP) Devices

WhitePapers

SECURITY

https://www.opencompute.org/documents/ibm-white-paper-ownership-and-control-of-firmware-in-open-compute-project-devices

OPEN SYSTEMS FIRMWARE

MANAGEMENT

Page 4: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

Contents

4IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

Why the paper?

What problem are we trying to solve?

Ownership InitializationTransfer

Open Compute Project Tenets

Page 5: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

5IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

We thought everyone knew this stuff (but realized they didn't)

It’s easy to do it right.

Why the paper?

“It’s déjà vu all over again.”

Yogi Berra

Smart cards, hardware security modules, server motherboards, Trusted Platform Modules, adapters, . . .

Page 6: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

6IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

It is an IBM Contribution to OCP.

Why the paper?

It affects multiple OCP groups

Security

Open System Firmware

Hardware Management (Open BMC)

Page 7: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

How do we transfer ownership securely?

How do we transfer ownership when we don’t know who the next owner is?

Who owns field replacement parts?

7IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

What problem are we trying to solve?

“If you don’t own your firmware, your firmware owns you.”

Ron Minnich, Google Software Engineer,

Linux Security Summit, Vancouver, 2018

How do we initialize a device with information about its owner?

How do we prevent an attacker from establishing ownership of a device?

Page 8: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

AdministratorAuthority OfficerOwner

8IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

An owner controls what firmware is allowed to run on a device.

Page 9: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

in physical control of the device

the one who holds intellectual property rights over it

the one who purchased the device

9IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

An owner is not necessarily. . .

Page 10: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

Secure boot Authenticated updatePower On Self Test

10IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

One device may have multiple owners (all at once or across its lifetime)

Hypervisor Operating System Application

Manufacturing tests

Page 11: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

Imprinting in the field

11IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

You must be my mother owner

You must be my baby device

First come first served

Initialization

“Rubber Duck” by gnokii is licensed under Creative Commons Zero 1.0 Public Domain License“Rubber Duck” by gnokii is licensed under Creative Commons Zero 1.0 Public Domain License, flipped horizontal“Hardware Technician” by Juhele is licensed under Creative Commons Zero 1.0 Public Domain License,, ducks added

Page 12: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

Some attacks on imprintingGood credentials / bad device or bad credentials / good device

12IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

Hardware cloneTricks the owner into thinking it’s the right kind of device.

Owner issues legitimate credentials to malicious hardware.

Decoy fools mama duck into thinking it’s real.

Initialization

Software cloneTricks the owner into thinking it’s a real device.

Owner issues legitimate credentials to malicious software.

Duck call fools mama duck into thinking it’s real.

Get there firstAttacker initializes with its own keys, then tricks the owner into thinking it’s a pristine device.

Owner issues legitimate credentials to authentic, but compromised hardware.

Duckling cyborg fools mama duck into thinking it’s an ordinary duckling.

False credentialsAttacker tricks device to connect to false credentialing authority.

Attacker issues false credentials to legitimate device.

Buzzard fools duckling into thinking it’s its mother.

”Man-in-the-middle” (MITM) attacks are easy during imprinting, so use MITM-resistant protocols!

Page 13: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

Temporary Transport Keys(aka Service Keys)

13IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

Use this as your temporary mother owner

Works well when

• we know how many to produce with that key

• both parties can be trusted to guard shared secrets

Initialization

“Hand Truck” by gnokii is licensed under Creative Commons Zero 1.0 Public Domain License“Rubber Duck” by gnokii is licensed under Creative Commons Zero 1.0 Public Domain License, flipped horizontal“Rubber Duck” by gnokii is licensed under Creative Commons Zero 1.0 Public Domain License, recolored, patterned“Orange forklift loader with box” by br0nde under Creative Commons Zero 1.0 Public Domain License

Page 14: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

Problems with temporary transport keys

14IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

Is the transport key really unique to these parties?Did the seller put the same key in others’ devices too? What if other buyers use that key to attack my devices?

Initialization

How many to produce?The manufacturer must initialize the right number of devices with the transport key.

What if the next owner is unknown? How many should have that key?

Can we re-initialize unsold devices with different keys for a different buyer?

Can I trust the other party not to leak a shared secret?Did the seller leave our shared secret on a disk in an open manufacturing system?

How to initialize field stock?What keys do we put in spare parts sitting in the warehouse? They don’t belong to anyone yet.

Page 15: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

Permanent Keys at Manufacture

15IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

The device knows its identity and gets its credentials before it ever leaves the factory.

Works well when

• the device knows at least one owner before it leaves the factory

• the owner’s public key can be protected by hardware

Initialization

The IBM 4767-002

“Rubber Duck” by gnokii is licensed under Creative Commons Zero 1.0 Public Domain License“conveyor with robot arm” by jiricek72 is licensed under Creative Commons Zero 1.0 Public Domain License, added ducks

Page 16: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

Problems with permanent keys at manufacturing

16IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

How does the device protect the owner’s key that it holds? Does the device have tamper-protected / tamper-responding storage?

Initialization

Do I know at least one owner? A slight variation of “How many to produce?”

What if the buyer wants to sell it to someone else?Does the owner have to authorize it?

Will the device allow itself to be owned by someone else?

Page 17: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

17IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

Of course, there are hybrid schemes.

Initialization

“Rubber Duck” by gnokii is licensed under Creative Commons Zero 1.0 Public Domain License, original, flipped horizontal, recolored, patterned“Hand Truck” by gnokii is licensed under Creative Commons Zero 1.0 Public Domain License“Hardware Technician” by Juhele is licensed under Creative Commons Zero 1.0 Public Domain License, ducks added“Conveyor with robot arm” by jiricek72 is licensed under Creative Commons Zero 1.0 Public Domain License, added ducks“Orange forklift loader with box” by br0nde under Creative Commons Zero 1.0 Public Domain License

Page 18: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

18IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

Maintaining Ownership

Minimal requirements for maintaining and using ownership

Remember and write protect the owner’s public key (or a list of keys)

Verify the digital signature of firmware that was signed (elsewhere) using the owner’s private key

Page 19: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

Reversability

One bit

Previous Owner(s)

(one X.509 certificate)

Designated successor

(one X.509 certificate)

Current Owner

(one X.509 certificate)

19IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

Representing ownership in (a small amount of) persistent memory

Page 20: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

State machine

state: current ownerprevious ownerdesignated successorreversibility

command (digitally signed by current owner) withnew owner, new designated successor, new reversibility

20IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

Ownership transfer

command processor

Page 21: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

Command processing for an ordinary transfer

21IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

Ownership transfer

Accept digitally signed state change request containing at least one of. . . new owner,

new designated successor, and new revertible control flag

Start

If new owner provided, replace the previous owner with the current owner.If new owner provided, replace the current owner with the new owner.

If new revertible control flag provided, set revertible control flag to new value.If new designated successor provided, set designated successor to new value.

Read stored state containing current owner,previous owner, designated successor, and

current revertible control flag

Fail, leaving stored state

unchanged

no yes

Was adesignatedsuccessorpreviously

stored?

noyes

Is newowner

requested?

yes

Fail, leaving stored state

unchanged

no

Returnsuccess

Is newowner

equal todesignatedsuccessor?

no

yes

Page 22: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

22IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

Some of the handovers supported

• Direct, cancellable

• Direct, not cancellable

• Return to inventory

• Erase history

• Cancel handover

• Indirect, unknown successor

• Indirect, known successor

Ownership transfer

Page 23: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

23IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

Ownership transfer

[S1]

[C1]

[C4][S5]

[S3]

[S1]

[S2] [S4]

[C2]

[C3] [U2]

[U1]

UTO1

*designatedsuccessor

UTO2

PRU

NO

PRU

PRU

*

(control)

return toactive use

indirecthandover

complete

indirecthandover

complete

UTO2

**

start indirect handoverto known successor

to knownsuccessor

acceptownership

PRU

*

UTO2

SVC

YES

UTO2

SVC

NOPRU

SVC

PRU

NO

UTO2

SVC

NOby service keystate is controlled

state name/number

non-revertable transfer

state/transition to audit

* arbitrary contentno content

legend

from currentto previous

owner?

is revertible

release frommanufacturercontrol

initialrollover

UTO2

PRU

YES

start indirecthandoverto unknownsuccessor

handoverstart cancellable

successorto known

(only PRUis authorizedsuccessor)

controlled by current ownerRepublic of Utopia(UTO) Country CA

controlled by successorPeople's Republic of Utopia

(PRU) Country CA

previous owner

current owner

regular rolloveraccept ownership

direct handover

erase history

cancel handover

PRU ``factory state''

erase history

!

!

!

!

Page 24: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

24IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

Direct, cancellable handover

[S1]

[C1]

[C4][S5]

[S3]

[S1]

[S2] [S4]

[C2]

[C3] [U2]

[U1]

UTO1

*designatedsuccessor

UTO2PRU

NO

PRUPRU

*

(control)

return toactive use

indirecthandover

complete

indirecthandover

complete

UTO2

**

start indirect handoverto known successor

to knownsuccessor

acceptownership

PRU

*

UTO2SVC

YES

UTO2SVC

NOPRU

SVCPRU

NO

UTO2SVC

NOby service keystate is controlled

state name/number

non-revertable transfer

state/transition to audit

* arbitrary contentno content

legend

from currentto previous

owner?

is revertible

release frommanufacturercontrol

initialrollover

UTO2PRU

YES

start indirecthandoverto unknownsuccessor

handoverstart cancellable

successorto known

(only PRUis authorizedsuccessor)

controlled by current owner

Republic of Utopia(UTO) Country CA

controlled by successor

People's Republic of Utopia(PRU) Country CA

previous owner

current owner

regular rolloveraccept ownership

direct handover

erase history

cancel handover

PRU ``factory state''

erase history

!

!

!

!

Not sure if PRU will back out of the order

Page 25: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

Impact

improves the security of the supply chain

devices can manage their own update processes

Scalability

small enough for adapters

component of many devices

remote administration

longer histories

Openness

white paper makes the technology and techniques known to others

Efficiency

storage < 6K bytes

signature verification code (likely there anyway for firmware)

command processing and state machine

25IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

OCP Tenets

Page 26: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

26IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

Get Involved

Check it out (overview) https://www.opencompute.org/projects/security

Dig deeper (project wiki)https://www.opencompute.org/wiki/Security

Follow us (mailing list)https://ocp-all.groups.io/g/OCP-Security

Participate weekly calls Tuesdays @ 8:30 a.m. PT

OCP Security Project – how to get involved

Page 27: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute

27IBM Research / FWOWN / Nov 06, 2018 / © 2018 IBM Corporation

Page 28: Ownership and Control of Firmware in Open Compute Project ...146a55aca6f00848c565-a7635525d40ac1c70300198708936b4e.ssl.cf1.rackcdn.…Ownership and Control of Firmware in Open Compute