This page is Almost Ready

Notice: The WebPlatform project, supported by various stewards between 2012 and 2015, has been discontinued. This site is now available on github.

peerIdentity

Summary

Contains the peer identity assertion information if an identity assertion was provided and verified.

Property of apis/webrtc/RTCPeerConnectionapis/webrtc/RTCPeerConnection

Syntax

Note: This property is read-only.

var result = element.peerIdentity;

Return Value

Returns an object of type RTCIdentityAssertionRTCIdentityAssertion

The RTCIdentityAssertion object has two string members:

  • idp - the domain name representing the identity provider
  • name - the name of the verified peer identity

Examples

This example shows how to consume identity assertions.

pc.onidentityresult = function(result) {
  console.log("IdP= " + pc.peerIdentity.idp +
              " identity=" + pc.peerIdentity.name);
};

Notes

The identity system is designed so that applications need not take any special action in order for users to generate and verify identity assertions; if a user has configured an IdP into their browser, then the browser will automatically request/generate assertions and the other side will automatically verify them and display the results.