Client API. The Codename One framework your app is built on: this runs on the device, not in a backend.

public enum DrmScheme

  1. Object
  2. Enum<DrmScheme>
  3. DrmScheme

ImplementsComparable<DrmScheme>

A content protection scheme a StreamRequest can ask the platform player to honour. Not every platform plays every scheme; ask MediaManager.isDrmSupported(DrmScheme) first and pick the strongest scheme the device answers yes to.

A streaming service usually packages each title once with CENC and serves it with whichever scheme the requesting device supports: FairPlay to Apple devices, Widevine to Android, and HLS AES-128 where neither is available.

Enum constants

AES_128HLS segment encryption with the key fetched from the URI of the playlist’s #EXT-X-KEY tag.
CLEARKEYThe W3C ClearKey key system: CENC-encrypted media with keys delivered as a JSON Web Key set.
WIDEVINEGoogle Widevine, the protection Android devices implement, with hardware-backed keys (L1) on most phones.
FAIRPLAYApple FairPlay Streaming, the protection iOS, iPadOS and tvOS implement.

Methods

public static DrmScheme[] values()
public static DrmScheme valueOf(String name)

Inherited methods

Enum constant details

AES_128

AES_128
HLS segment encryption with the key fetched from the URI of the playlist’s #EXT-X-KEY tag. Every native player that plays HLS decrypts it, so it works on the most devices. The key reaches the client in the clear (over TLS), which makes it a deterrent rather than hardware-backed protection: guard the key URL with a short-lived, per-session token.

CLEARKEY

CLEARKEY
The W3C ClearKey key system: CENC-encrypted media with keys delivered as a JSON Web Key set. The same packaging as Widevine without a license vendor, which makes it the scheme to develop and test a license server against.

WIDEVINE

WIDEVINE
Google Widevine, the protection Android devices implement, with hardware-backed keys (L1) on most phones.

FAIRPLAY

FAIRPLAY
Apple FairPlay Streaming, the protection iOS, iPadOS and tvOS implement. Needs the application certificate from Apple’s FairPlay program, set with DrmConfig.setCertificateUrl(String).

Method details

values

public static DrmScheme[] values()

valueOf

public static DrmScheme valueOf(String name)