PKey.GetPrivateKey
------------------

Queries private key as PEM file text.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [Certificates](component_Certificates.md) | [7.0](newinversion70.md) | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |

MBS( "PKey.GetPrivateKey"; PKeyRef ) 

**MBS**( **"PKey.GetPrivateKey";** /\* Queries private key as PEM file text. \*/  
**$PKeyRef**) /\* The reference to the private key.e.g. $pkey \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| PKeyRef | The reference to the private key. | $pkey |

### Result

Returns text or error.

### Description

Queries private key as PEM file text.  
### See also

- [ECKey.ReadPrivateKey](ECKeyReadPrivateKey.md)

### Blog Entries

- [MBS FileMaker Plugin, version 7.0pr2](https://www.mbsplugins.de/archive/2017-01-09/MBS_FileMaker_Plugin_version_7/monkeybreadsoftware_blog_filemaker)

This function checks for a license.

Created 23th December 2016 , last changed 23th December 2016

  
[PKey.DescriptionPublicKey](PKeyDescriptionPublicKey.md) - [PKey.GetPublicKey](PKeyGetPublicKey.md)

[HTML Version](PKeyGetPrivateKey.shtml)