ECKey.PrivateKey
----------------

Queries the private key.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [Sign](component_Sign.md) | [5.4](newinversion54.md) | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |

MBS( "ECKey.PrivateKey"; ECKey ) 

**MBS**( **"ECKey.PrivateKey";** /\* Queries the private key. \*/  
**$ECKey**) /\* The reference number for the key.e.g. $Key \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| ECKey | The reference number for the key. | $Key |

### Result

Returns text or error.

### Description

Queries the private key.  
Returned as hex encoded text.  
### Examples

Generate keys and store in fields:

 Set Variable \[$key ; Value:MBS ("[ECKey.Generate](ECKeyGenerate.md)"; 711)\]  
Set Field \[ECKey Test::KeyInfo ; MBS ("[ECKey.Description](ECKeyDescription.md)"; $key )\]  
Set Field \[ECKey Test::PrivateKey ; MBS ("ECKey.PrivateKey"; $key )\]  
Set Field \[ECKey Test::PublicKey ; MBS ("[ECKey.PublicKey](ECKeyPublicKey.md)"; $key )\]  
Set Variable \[$r ; Value:MBS ("[ECKey.Release](ECKeyRelease.md)"; $key )\]  
### See also

- [ECKey.Description](ECKeyDescription.md)
- [ECKey.Generate](ECKeyGenerate.md)
- [ECKey.PublicKey](ECKeyPublicKey.md)
- [ECKey.ReadPrivateKey](ECKeyReadPrivateKey.md)
- [ECKey.Release](ECKeyRelease.md)

### Example Databases

- [Encryption and Hash/ECKey Test](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/Encryption%20and%20Hash/ECKey%20Test.shtml#1ScriptAnchor_)
- [Encryption and Hash/Solution Registration/Solution Registration Creator](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/Encryption%20and%20Hash/Solution%20Registration/Solution%20Registration%20Creator.shtml#1ScriptAnchor_)

### FileMaker Magazin

- [Ausgabe 6/2015, Seite 29](https://filemaker-magazin.de/neuigkeit/3855-Appetithappen-FMM_201506)

This function checks for a license.

Created 9th October 2015 , last changed 14th October 2015

  
[ECKey.List](ECKeyList.md) - [ECKey.PublicKey](ECKeyPublicKey.md)

[HTML Version](ECKeyPrivateKey.shtml)