mirror of
https://github.com/FeitianTech/u2f-ref-code.git
synced 2026-08-28 10:40:37 -07:00
- Require explicit user approval on registration - Embed eTLD list instead of fetching remotel - Support compressed requests (single appId and challenge) - Do not reveal to webpage if that a device is enrolled without explicit user action - Smaller bugfixes
34 lines
661 B
JavaScript
34 lines
661 B
JavaScript
// Copyright 2014 Google Inc. All rights reserved
|
|
//
|
|
// Use of this source code is governed by a BSD-style
|
|
// license that can be found in the LICENSE file or at
|
|
// https://developers.google.com/open-source/licenses/bsd
|
|
|
|
/**
|
|
* @fileoverview Errors reported by top-level request handlers.
|
|
*/
|
|
'use strict';
|
|
|
|
/**
|
|
* Response status codes
|
|
* @const
|
|
* @enum {number}
|
|
*/
|
|
var ErrorCodes = {
|
|
'OK': 0,
|
|
'OTHER_ERROR': 1,
|
|
'BAD_REQUEST': 2,
|
|
'CONFIGURATION_UNSUPPORTED': 3,
|
|
'DEVICE_INELIGIBLE': 4,
|
|
'TIMEOUT': 5
|
|
};
|
|
|
|
/**
|
|
* An error object for responses
|
|
* @typedef {{
|
|
* errorCode: ErrorCodes,
|
|
* errorMessage: (?string|undefined)
|
|
* }}
|
|
*/
|
|
var U2fError;
|