<!--
{
  "availability" : [
    "iOS: 16.0.0 -",
    "iPadOS: 16.0.0 -",
    "macCatalyst: 16.0.0 -",
    "macOS: 13.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "LocalAuthentication",
  "identifier" : "/documentation/LocalAuthentication/LAPrivateKey",
  "metadataVersion" : "0.1.0",
  "role" : "Class",
  "symbol" : {
    "kind" : "Class",
    "modules" : [
      "Local Authentication"
    ],
    "preciseIdentifier" : "c:objc(cs)LAPrivateKey"
  },
  "title" : "LAPrivateKey"
}
-->

# LAPrivateKey

The private portion of an asymmetric key pair.

```
class LAPrivateKey
```

## Topics

### Accessing the associated public key

[`publicKey`](/documentation/LocalAuthentication/LAPrivateKey/publicKey)

The public key that corresponds with the private key in a key pair.

### Checking algorithm support

[`-  canDecryptUsingSecKeyAlgorithm:`](/documentation/LocalAuthentication/LAPrivateKey/canDecrypt(using:))

Checks whether the algorithm you supply is valid for decrypting data with the key.

[`-  canExchangeKeysUsingSecKeyAlgorithm:`](/documentation/LocalAuthentication/LAPrivateKey/canExchangeKeys(using:))

Checks whether the algorithm you supply is valid for performing key exchanges.

[`-  canSignUsingSecKeyAlgorithm:`](/documentation/LocalAuthentication/LAPrivateKey/canSign(using:))

Checks whether the algorithm you supply is valid for signing data with the key.

### Performing cryptographic operations

[`-  decryptData:secKeyAlgorithm:completion:`](/documentation/LocalAuthentication/LAPrivateKey/decrypt(_:algorithm:completion:))

Decrypts the data you supply with a given algorithm.

[`-  exchangeKeysWithPublicKey:secKeyAlgorithm:secKeyParameters:completion:`](/documentation/LocalAuthentication/LAPrivateKey/exchangeKeys(publicKey:algorithm:parameters:completion:))

Performs a Diffie-Hellman style key exchange operation.

[`-  signData:secKeyAlgorithm:completion:`](/documentation/LocalAuthentication/LAPrivateKey/sign(_:algorithm:completion:))

Generates a digital signature for the data you supply.

## Relationships

### Conforms To

[`CVarArg`](/documentation/Swift/CVarArg)

[`Hashable`](/documentation/Swift/Hashable)

[`CustomStringConvertible`](/documentation/Swift/CustomStringConvertible)

[`Equatable`](/documentation/Swift/Equatable)

[`NSObjectProtocol`](/documentation/ObjectiveC/NSObjectProtocol)

[`CustomDebugStringConvertible`](/documentation/Swift/CustomDebugStringConvertible)

### Inherits From

[`NSObject-swift.class`](/documentation/ObjectiveC/NSObject-swift.class)

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)