Skip to content

Commit dacede2

Browse files
committed
feat: add new authenticator transport constants and deprecate AUTHENTICATOR_TRANSPORT_CABLE
1 parent d260f80 commit dacede2

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed

phpstan-baseline.neon

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2321,3 +2321,12 @@ parameters:
23212321
identifier: return.type
23222322
count: 1
23232323
path: src/webauthn/src/SimpleFakeCredentialGenerator.php
2324+
2325+
-
2326+
rawMessage: '''
2327+
Fetching deprecated class constant AUTHENTICATOR_TRANSPORT_CABLE of class Webauthn\PublicKeyCredentialDescriptor:
2328+
Please use AUTHENTICATOR_TRANSPORT_BLE instead. Will be removed in 6.0.0
2329+
'''
2330+
identifier: classConstant.deprecated
2331+
count: 1
2332+
path: src/webauthn/src/PublicKeyCredentialDescriptor.php

src/webauthn/src/PublicKeyCredentialDescriptor.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,15 +14,24 @@ class PublicKeyCredentialDescriptor
1414

1515
final public const AUTHENTICATOR_TRANSPORT_BLE = 'ble';
1616

17+
/**
18+
* @deprecated Please use AUTHENTICATOR_TRANSPORT_BLE instead. Will be removed in 6.0.0
19+
*/
1720
final public const AUTHENTICATOR_TRANSPORT_CABLE = 'cable';
1821

22+
final public const AUTHENTICATOR_TRANSPORT_SMART_CARD = 'smart-card';
23+
24+
final public const AUTHENTICATOR_TRANSPORT_HYBRID = 'hybrid';
25+
1926
final public const AUTHENTICATOR_TRANSPORT_INTERNAL = 'internal';
2027

2128
final public const AUTHENTICATOR_TRANSPORTS = [
2229
self::AUTHENTICATOR_TRANSPORT_USB,
2330
self::AUTHENTICATOR_TRANSPORT_NFC,
2431
self::AUTHENTICATOR_TRANSPORT_BLE,
2532
self::AUTHENTICATOR_TRANSPORT_CABLE,
33+
self::AUTHENTICATOR_TRANSPORT_SMART_CARD,
34+
self::AUTHENTICATOR_TRANSPORT_HYBRID,
2635
self::AUTHENTICATOR_TRANSPORT_INTERNAL,
2736
];
2837

0 commit comments

Comments
 (0)