Skip to content

Releases: peterferguson/react-native-passkeys

v0.4.0 - PRF evalByCredential & credProps Extension Support

07 Oct 14:51

Choose a tag to compare

react-native-passkeys v0.4.0 πŸŽ‰

A significant release adding advanced WebAuthn extensions support and improving cross-platform consistency.

πŸš€ New Features

PRF Extension - Complete Support

The PRF (Pseudo-Random Function) extension is now fully supported, allowing you to derive cryptographic keys from credentials. This release adds evalByCredential support on top of the existing eval functionality.

Using eval for single PRF input:

// Derive a key using a single salt input
await passkey.get({
  rpId: "example.com",
  challenge: "...",
  extensions: {
    prf: {
      eval: {
        first: "base64url-encoded-salt",
        // optional second salt
        second: "base64url-encoded-salt-2",
      },
    },
  },
});

Using evalByCredential for per-credential inputs:

// Derive different keys for different credentials
await passkey.get({
  rpId: "example.com",
  challenge: "...",
  extensions: {
    prf: {
      evalByCredential: {
        [credentialId]: {
          first: "base64url-encoded-salt",
          // optional second salt
        },
      },
    },
  },
  allowCredentials: [{ id: credentialId, type: "public-key" }],
});

Platform Support:

  • βœ… iOS 18+
  • βœ… Android API 34+
  • βœ… Web (all modern browsers with WebAuthn Level 3)

Spec Compliance:

credProps Extension Support

The credential properties extension (credProps) is now supported, allowing you to determine whether a credential is a client-side discoverable credential (passkey).

const result = await passkey.create({
  // ... other options
  extensions: {
    credProps: true,
  },
});

// Check if the credential is discoverable
const isDiscoverable = result?.clientExtensionResults?.credProps?.rk;

Platform Support:

  • βœ… Android API 34+
  • βœ… Web
  • 🚧 iOS (types included, implementation pending)

✨ Improvements

Cross-Platform Consistency

  • getPublicKey() Normalization: Now returns Base64URLString on all platforms instead of ArrayBuffer on web. This provides a consistent API across iOS, Android, and Web.

Enhanced Type Safety

  • Improved TypeScript types for credential responses
  • Better type inference for extension outputs
  • More precise types for PRF inputs and outputs

Better Error Handling

  • Enhanced input validation on iOS
  • Better error messages for invalid PRF inputs
  • Improved exception handling across all platforms

Documentation

  • Comprehensive JSDoc comments across Android and iOS implementations
  • Updated example app demonstrating new features
  • Improved inline documentation for extension types

πŸ“± Example App Updates

  • Add demonstration of evalByCredential usage
  • Upgrade to Expo SDK 54
  • Upgrade Android compile SDK to 36
  • Improve type safety and UI handling
  • Add type definitions for @hexagon/base64

⚠️ Breaking Changes

getPublicKey() Return Type (Web only)

Previously on web, getPublicKey() returned ArrayBuffer | null. It now returns Base64URLString | null for consistency with iOS and Android implementations.

Migration:

// Before (web only)
const publicKeyBuffer = response.getPublicKey();
// convert to base64url manually

// After (all platforms)
const publicKeyBase64 = response.getPublicKey();
// Already in base64url format, ready to send to server

πŸ“š Related Issues & PRs

  • Closes #31 - Apple and iOS WebAuthn PRF support
  • Builds on #51 - feat: add support for PRF (eval) by @sparten11740
  • Part of ongoing WebAuthn Level 3 compliance work

πŸ™ Acknowledgments

Thanks to @sparten11740 (Jan W) for the initial PRF implementation that this release builds upon.


Full Changelog: v0.3.3...v0.4.0

v0.3.3

07 Oct 14:26

Choose a tag to compare

react-native-passkeys v0.3.3

Minor release with no functional changes.


Full Changelog: v0.3.2...v0.3.3

v0.3.2

07 Oct 14:26

Choose a tag to compare

react-native-passkeys v0.3.2

πŸ› Bug Fixes

iOS Safari Large Blob Fix

Fixed a crash in iOS Safari when requesting a largeBlob credential with an empty object using the get() method.

Solution: The extension now passes undefined if the request does not include a largeBlob object, preventing the crash.


Full Changelog: v0.3.1...v0.3.2

v0.3.1

07 Oct 14:25

Choose a tag to compare

react-native-passkeys v0.3.1

πŸš€ New Features

getPublicKey Method

Added getPublicKey() method to credential responses, allowing you to retrieve the public key of a newly created credential.

const result = await passkey.create({
  // ... options
});

const publicKey = result?.response.getPublicKey();

πŸ› Bug Fixes

  • Fixed Android support for Expo SDK 51
  • Fixed default attestation preference to none on iOS

Full Changelog: v0.3.0...v0.3.1

v0.3.0 - Public Key Access & Expo SDK 51

06 Oct 09:57
9bdbbcf

Choose a tag to compare

✨ New Features & Improvements

This release adds the ability to retrieve public keys from credentials and updates framework compatibility.

🎯 New Features

  • πŸ”‘ Added getPublicKey() method to retrieve public keys from credentials (PRs #20, #21, #22)
    • iOS implementation with CBOR decoding
    • Web implementation
    • Android implementation
  • πŸ“± React Native 0.74 support (PR #18 by @ashtar23)
  • πŸ“¦ Expo SDK 51 compatibility (PR #18 by @ashtar23)

πŸ› Bug Fixes

  • Fixed none and default attestation kind on iOS (PR #16 by @cruzdanilo)
  • Fixed Xcode 15.3 build issues (PR #11)

πŸ”§ Developer Experience

  • Converted Android example to use expo-dev-client
  • Updated example app to SDK 51
  • Added public key getter UI to example app
  • Updated README documentation

πŸ”— Full Changelog

v0.2.2 - Android Support

06 Oct 09:57

Choose a tag to compare

πŸŽ‰ Android Support Added!

This release brings full Android support to react-native-passkeys.

✨ New Features

  • πŸ€– Android implementation using CredentialManager API (PR #5 by @andrew-levy)
  • πŸ“± Expo SDK 50 compatibility for Android (PR #6 by @BubbleTrouble14)

πŸ› Bug Fixes

  • Fixed issue when using with Expo 50 on Android
  • Added guard for excludedCredentials to prevent crashes
  • Fixed largeBlob handling on web with TypeScript ignore comment

πŸ“š Documentation

  • Improved Android setup documentation
  • Added error handling examples

Supported Platforms

  • βœ… iOS
  • βœ… Android (NEW!)
  • βœ… Web

πŸ”— Full Changelog

v0.1.6

06 Oct 09:56

Choose a tag to compare

What Changed

πŸ”§ Improvements

  • Updated client extension types for better WebAuthn compatibility
  • Fixed AuthenticatorSelectionCriteria type to use proper Record type

πŸ”— Full Changelog

v0.1.4

06 Oct 09:56

Choose a tag to compare

What Changed

πŸ”§ Improvements

  • Removed only-allow preinstall hook to improve package manager compatibility

πŸ”— Full Changelog

v0.1.3

06 Oct 09:56

Choose a tag to compare

What Changed

πŸ”§ Improvements

  • Updated type definitions to extend @simplewebauthn/types for better TypeScript support
  • Improved type compatibility with the SimpleWebAuthn ecosystem

πŸ”— Full Changelog

v0.1.2 - Initial Release

06 Oct 09:55

Choose a tag to compare

πŸŽ‰ Initial Release

This is the initial release of react-native-passkeys, providing WebAuthn/Passkeys support for React Native applications.

Features

  • ✨ Initial iOS implementation using AuthenticationServices framework
  • 🌐 Web implementation for browser compatibility
  • πŸ“± Basic passkey registration and authentication support

Supported Platforms

  • iOS
  • Web

πŸ”— Full Changelog