p≡p JSON adapter
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

730 lines
26 KiB

  1. ### Detailed Function reference for the p≡p JSON Server Adapter. Version “(38) Frankenberg”, API version 0.15.0 ###
  2. Output parameters are denoted by a **⇑** , InOut parameters are denoted by a **⇕** after the parameter type.
  3. Nota bene: This list was created manually from the "authorative API description" and might be outdated.
  4. #### Message API ####
  5. ##### MIME_encrypt_message( String mimetext, Integer size, StringList extra, String⇑ mime_ciphertext, PEP_enc_format env_format, Integer flags)
  6. encrypt a MIME message, with MIME output
  7. ```
  8. parameters:
  9. mimetext (in) MIME encoded text to encrypt
  10. size (in) size of input mime text
  11. extra (in) extra keys for encryption
  12. mime_ciphertext (out) encrypted, encoded message
  13. enc_format (in) encrypted format
  14. flags (in) flags to set special encryption features
  15. return value:
  16. PEP_STATUS_OK if everything worked
  17. PEP_BUFFER_TOO_SMALL if encoded message size is too big to handle
  18. PEP_CANNOT_CREATE_TEMP_FILE
  19. if there are issues with temp files; in
  20. this case errno will contain the underlying
  21. error
  22. PEP_OUT_OF_MEMORY if not enough memory could be allocated
  23. ```
  24. *Caveat:* the encrypted, encoded mime text will go to the ownership of the caller; mimetext
  25. will remain in the ownership of the caller
  26. ##### MIME_encrypt_message_for_self( Identity target_id, String mimetext, Integer size, StringList extra, String⇑ mime_ciphertext, PEP_enc_format enc_format, Integer flags) #####
  27. encrypt MIME message for user's identity only, ignoring recipients and other identities from
  28. the message, with MIME output
  29. ```
  30. parameters:
  31. target_id (in) self identity this message should be encrypted for
  32. mimetext (in) MIME encoded text to encrypt
  33. size (in) size of input mime text
  34. extra (in) extra keys for encryption
  35. mime_ciphertext (out) encrypted, encoded message
  36. enc_format (in) encrypted format
  37. flags (in) flags to set special encryption features
  38. return value:
  39. PEP_STATUS_OK if everything worked
  40. PEP_BUFFER_TOO_SMALL if encoded message size is too big to handle
  41. PEP_CANNOT_CREATE_TEMP_FILE
  42. if there are issues with temp files; in
  43. this case errno will contain the underlying
  44. error
  45. PEP_OUT_OF_MEMORY if not enough memory could be allocated
  46. caveat:
  47. the encrypted, encoded mime text will go to the ownership of the caller; mimetext
  48. will remain in the ownership of the caller
  49. ```
  50. ##### MIME_decrypt_message(String mimetext, Integer size, String⇑ mime_plaintext, StringList⇑ keylist, PEP_rating⇑ rating, Integer⇕ flags, String⇑ modified_src)
  51. decrypt a MIME message, with MIME output
  52. ```
  53. parameters:
  54. mimetext (in) MIME encoded text to decrypt
  55. size (in) size of mime text to decode (in order to decrypt)
  56. mime_plaintext (out) decrypted, encoded message
  57. keylist (out) stringlist with keyids
  58. rating (out) rating for the message
  59. flags (inout) flags to signal special decryption features
  60. modified_src (out) modified source string, if decrypt had reason to change it
  61. return value:
  62. decrypt status if everything worked with MIME encode/decode,
  63. the status of the decryption is returned
  64. (PEP_STATUS_OK or decryption error status)
  65. PEP_BUFFER_TOO_SMALL if encoded message size is too big to handle
  66. PEP_CANNOT_CREATE_TEMP_FILE
  67. if there are issues with temp files; in
  68. this case errno will contain the underlying
  69. error
  70. PEP_OUT_OF_MEMORY if not enough memory could be allocated
  71. flag values:
  72. in:
  73. PEP_decrypt_flag_untrusted_server
  74. used to signal that decrypt function should engage in behaviour
  75. specified for when the server storing the source is untrusted.
  76. out:
  77. PEP_decrypt_flag_own_private_key
  78. private key was imported for one of our addresses (NOT trusted
  79. or set to be used - handshake/trust is required for that)
  80. PEP_decrypt_flag_src_modified
  81. indicates that the modified_src field should contain a modified
  82. version of the source, at the moment always as a result of the
  83. input flags.
  84. PEP_decrypt_flag_consume
  85. used by sync
  86. PEP_decrypt_flag_ignore
  87. used by sync
  88. caveat:
  89. the decrypted, encoded mime text will go to the ownership of the caller; mimetext
  90. will remain in the ownership of the caller
  91. ```
  92. ##### startKeySync()
  93. Start Key Synchronization for the current session.
  94. ##### stopKeySync()
  95. Stop Key Synchronization for the current session.
  96. ##### startKeyserverLookup()
  97. Start a global thread for Keyserver Lookup. This thread handles all keyserver communication for all sessions.
  98. ##### stopKeyserverLookup()
  99. Stop the global thread for Keyserver Lookup.
  100. ##### encrypt_message(Message src, StringList extra_keys, Message⇑ dst, PEP_enc_format enc_format, Integer flags)
  101. encrypt message in memory
  102. ```
  103. parameters:
  104. src (in) message to encrypt
  105. extra_keys (in) extra keys for encryption
  106. dst (out) pointer to new encrypted message or NULL on failure
  107. enc_format (in) encrypted format
  108. flags (in) flags to set special encryption features
  109. return value:
  110. PEP_STATUS_OK on success
  111. PEP_KEY_NOT_FOUND at least one of the receipient keys
  112. could not be found
  113. PEP_KEY_HAS_AMBIG_NAME at least one of the receipient keys has
  114. an ambiguous name
  115. PEP_GET_KEY_FAILED cannot retrieve key
  116. PEP_UNENCRYPTED no recipients with usable key,
  117. message is left unencrypted,
  118. and key is attached to it
  119. ```
  120. ##### encrypt_message_for_self(Identity target_id, Message src, Message⇑ dst, PEP_enc_format enc_format, Integer flags)
  121. encrypt message in memory for user's identity only,
  122. ignoring recipients and other identities from
  123. the message.
  124. ```
  125. parameters:
  126. target_id (in) self identity this message should be encrypted for
  127. src (in) message to encrypt
  128. dst (out) pointer to new encrypted message or NULL on failure
  129. enc_format (in) encrypted format
  130. flags (in) flags to set special encryption features
  131. return value: (FIXME: This may not be correct or complete)
  132. PEP_STATUS_OK on success
  133. PEP_KEY_NOT_FOUND at least one of the receipient keys
  134. could not be found
  135. PEP_KEY_HAS_AMBIG_NAME at least one of the receipient keys has
  136. an ambiguous name
  137. PEP_GET_KEY_FAILED cannot retrieve key
  138. ```
  139. *Caveat:* message is NOT encrypted for identities other than the target_id (and then,
  140. only if the target_id refers to self!)
  141. ##### decrypt_message(Message⇕ src, Message⇑ dst, StringList⇑ keylist, PEP_rating⇑ rating, Integer⇕ flags)
  142. decrypt message in memory
  143. ```
  144. parameters:
  145. src (inout) message to decrypt
  146. dst (out) pointer to new decrypted message or NULL on failure
  147. keylist (out) stringlist with keyids
  148. rating (out) rating for the message
  149. flags (inout) flags to signal special decryption features
  150. return value:
  151. error status
  152. or PEP_DECRYPTED if message decrypted but not verified
  153. or PEP_CANNOT_REENCRYPT if message was decrypted (and possibly
  154. verified) but a reencryption operation is expected by the caller
  155. and failed
  156. or PEP_STATUS_OK on success
  157. flag values:
  158. in:
  159. PEP_decrypt_flag_untrusted_server
  160. used to signal that decrypt function should engage in behaviour
  161. specified for when the server storing the source is untrusted
  162. out:
  163. PEP_decrypt_flag_own_private_key
  164. private key was imported for one of our addresses (NOT trusted
  165. or set to be used - handshake/trust is required for that)
  166. PEP_decrypt_flag_src_modified
  167. indicates that the src object has been modified. At the moment,
  168. this is always as a direct result of the behaviour driven
  169. by the input flags. This flag is the ONLY value that should be
  170. relied upon to see if such changes have taken place.
  171. PEP_decrypt_flag_consume
  172. used by sync
  173. PEP_decrypt_flag_ignore
  174. used by sync
  175. caveat:
  176. the ownership of src remains with the caller - however, the contents
  177. might be modified (strings freed and allocated anew or set to NULL,
  178. etc) intentionally; when this happens, PEP_decrypt_flag_src_modified
  179. is set.
  180. the ownership of dst goes to the caller
  181. the ownership of keylist goes to the caller
  182. if src is unencrypted this function returns PEP_UNENCRYPTED and sets
  183. dst to NULL
  184. ```
  185. ##### outgoing_message_rating(Message msg, PEP_rating⇑ rating)
  186. get rating for an outgoing message
  187. ```
  188. parameters:
  189. msg (in) message to get the rating for
  190. rating (out) rating for the message
  191. return value:
  192. error status or PEP_STATUS_OK on success
  193. caveat:
  194. msg->from must point to a valid pEp_identity
  195. msg->dir must be PEP_dir_outgoing
  196. ```
  197. ##### re_evaluate_message_rating(Message msg, StringList keylist, PEP_rating enc_status, PEP_rating⇑ rating)
  198. re-evaluate already decrypted message rating
  199. ```
  200. parameters:
  201. msg (in) message to get the rating for
  202. keylist (in) decrypted message recipients keys fpr
  203. enc_status (in) original rating for the decrypted message
  204. rating (out) rating for the message
  205. return value:
  206. PEP_ILLEGAL_VALUE if decrypted message doesn't contain
  207. X-EncStatus optional field and x_enc_status is
  208. pEp_rating_udefined
  209. or if decrypted message doesn't contain
  210. X-Keylist optional field and x_keylist is NULL
  211. PEP_OUT_OF_MEMORY if not enough memory could be allocated
  212. caveat:
  213. msg->from must point to a valid pEp_identity
  214. ```
  215. ##### identity_rating(Identity ident, PEP_rating⇑ rating)
  216. get rating for a single identity
  217. ```
  218. parameters:
  219. ident (in) identity to get the rating for
  220. rating (out) rating for the identity
  221. return value:
  222. error status or PEP_STATUS_OK on success
  223. ```
  224. ##### get_gpg_path(String⇑)
  225. get path of gpg binary.
  226. #### pEp Engine Core API ####
  227. ##### get_trustwords(Identity id1, Identity id2, Language lang, String⇑ words, Integer⇑ wsize, Bool full)
  228. get full trustwords string for a *pair* of identities
  229. ```
  230. parameters:
  231. id1 (in) identity of first party in communication - fpr can't be NULL
  232. id2 (in) identity of second party in communication - fpr can't be NULL
  233. lang (in) C string with ISO 639-1 language code
  234. words (out) pointer to C string with all trustwords UTF-8 encoded,
  235. separated by a blank each
  236. NULL if language is not supported or trustword
  237. wordlist is damaged or unavailable
  238. wsize (out) length of full trustwords string
  239. full (in) if true, generate ALL trustwords for these identities.
  240. else, generate a fixed-size subset. (TODO: fixed-minimum-entropy
  241. subset in next version)
  242. return value:
  243. PEP_STATUS_OK trustwords retrieved
  244. PEP_OUT_OF_MEMORY out of memory
  245. PEP_TRUSTWORD_NOT_FOUND at least one trustword not found
  246. ```
  247. ##### get_languagelist(String⇑ languages)
  248. get the list of languages
  249. ```
  250. parameters:
  251. languages (out) languages as string in double quoted CSV format
  252. column 1 is the ISO 639-1 language code
  253. column 2 is the name of the language
  254. ```
  255. ##### is_pep_user(Identity id, Bool⇑ ia_pwp)
  256. returns true if the USER corresponding to this identity has been listed in the *person* table as a pEp user
  257. ```
  258. parameters:
  259. identity (in) - identity containing the user_id to check (this is
  260. the only part of the struct we require to be set)
  261. is_pep (out) - boolean pointer - will return true or false by
  262. reference with respect to whether or not user is
  263. a known pep user
  264. ```
  265. ##### config_passive_mode(Bool enable)
  266. enable passive mode
  267. * parameters: enable (in) flag if enabled or disabled
  268. ##### config_unencrypted_subject(Bool enable)
  269. disable subject encryption
  270. * parameters: enable (in) flag if enabled or disabled
  271. #### Identity Management API ####
  272. ##### get_identity(String address, String user_id, Identity⇑ identity)
  273. get identity information
  274. ```
  275. parameters:
  276. address (in) string with communication address, UTF-8 encoded
  277. user_id (in) unique string to identify person that identity is refering to
  278. identity (out) pEp_identity structure with results or NULL if failure
  279. ```
  280. ##### set_identity(Identity)
  281. set identity information
  282. ```
  283. parameters:
  284. identity (in) pEp_identity structure
  285. return value:
  286. PEP_STATUS_OK = 0 encryption and signing succeeded
  287. PEP_CANNOT_SET_PERSON writing to table person failed
  288. PEP_CANNOT_SET_PGP_KEYPAIR writing to table pgp_keypair failed
  289. PEP_CANNOT_SET_IDENTITY writing to table identity failed
  290. PEP_COMMIT_FAILED SQL commit failed
  291. PEP_KEY_BLACKLISTED Key blacklisted, cannot set identity
  292. caveat:
  293. address, fpr, user_id and username must be given
  294. ```
  295. ##### mark_as_comprimized(String fpr)
  296. mark key in trust db as compromized
  297. * parameters: fpr (in) fingerprint of key to mark
  298. ##### identity_rating(Identity ident, PEP_rating⇑ rating)
  299. get rating for a single identity
  300. ```
  301. parameters:
  302. ident (in) identity to get the rating for
  303. rating (out) rating for the identity
  304. return value:
  305. error status or PEP_STATUS_OK on success
  306. ```
  307. ##### outgoing_message_rating(Message msg, PEP_rating⇑ rating)
  308. get rating for an outgoing message
  309. ```
  310. parameters:
  311. msg (in) message to get the rating for
  312. rating (out) rating for the message
  313. return value:
  314. error status or PEP_STATUS_OK on success
  315. caveat:
  316. msg->from must point to a valid pEp_identity
  317. msg->dir must be PEP_dir_outgoing
  318. ```
  319. ##### set_identity_flags(Identity⇕ identity, Integer flags)
  320. update identity flags on existing identity
  321. ```
  322. parameters:
  323. identity (in,out) pointer to pEp_identity structure
  324. flags (in) new value for flags
  325. return value:
  326. PEP_STATUS_OK = 0 encryption and signing succeeded
  327. PEP_CANNOT_SET_IDENTITY update of identity failed
  328. caveat:
  329. address and user_id must be given in identity
  330. ```
  331. ##### unset_identity_flags(Identity⇕ identity, Integer flags)
  332. update identity flags on existing identity
  333. ```
  334. parameters:
  335. identity (in,out) pointer to pEp_identity structure
  336. flags (in) new value for flags
  337. return value:
  338. PEP_STATUS_OK = 0 encryption and signing succeeded
  339. PEP_CANNOT_SET_IDENTITY update of identity failed
  340. caveat:
  341. address and user_id must be given in identity
  342. ```
  343. #### Low level Key Management API ####
  344. ##### generate_keypair(Identity⇕ identity)
  345. generate a new key pair and add it to the key ring
  346. ```
  347. parameters:
  348. identity (inout) pEp_identity structure
  349. return value:
  350. PEP_STATUS_OK = 0 encryption and signing succeeded
  351. PEP_ILLEGAL_VALUE illegal values for identity fields given
  352. PEP_CANNOT_CREATE_KEY key engine is on strike
  353. caveat:
  354. address and username fields must be set to UTF-8 strings
  355. the fpr field must be set to NULL
  356. ```
  357. ##### delete_keypair(String fpr)
  358. delete a public key or a key pair from the key ring
  359. ```
  360. parameters:
  361. fpr (in) string with key id or fingerprint of the public key
  362. return value:
  363. PEP_STATUS_OK = 0 key was successfully deleted
  364. PEP_KEY_NOT_FOUND key not found
  365. PEP_ILLEGAL_VALUE not a valid key id or fingerprint
  366. PEP_KEY_HAS_AMBIG_NAME fpr does not uniquely identify a key
  367. PEP_OUT_OF_MEMORY out of memory
  368. ```
  369. ##### import_key(String key_data, Integer size, IdentityList⇑ private_keys)
  370. import key from data
  371. ```
  372. parameters:
  373. key_data (in) key data, i.e. ASCII armored OpenPGP key
  374. size (in) amount of data to handle
  375. private_keys (out) list of private keys that have been imported
  376. return value:
  377. PEP_STATUS_OK = 0 key was successfully imported
  378. PEP_OUT_OF_MEMORY out of memory
  379. PEP_ILLEGAL_VALUE there is no key data to import
  380. ```
  381. ##### export_key(String fpr, String⇑ key_data, Integer⇑ size)
  382. export ascii armored key
  383. ```
  384. parameters:
  385. fpr (in) key id or fingerprint of key
  386. key_data (out) ASCII armored OpenPGP key
  387. size (out) amount of data to handle
  388. return value:
  389. PEP_STATUS_OK = 0 key was successfully exported
  390. PEP_OUT_OF_MEMORY out of memory
  391. PEP_KEY_NOT_FOUND key not found
  392. ```
  393. ##### find_keys(String pattern, StringList⇑ keylist)
  394. find keys in keyring
  395. ```
  396. parameters:
  397. pattern (in) key id, user id or address to search for as UTF-8 string
  398. keylist (out) list of fingerprints found or NULL on error
  399. ```
  400. ##### get_trust(Identity⇕ identity)
  401. get the trust level a key has for a person
  402. ```
  403. parameters:
  404. identity (inout) user_id and fpr to check as UTF-8 strings (in)
  405. user_id and comm_type as result (out)
  406. ```
  407. This function modifies the given identity struct; the struct remains in
  408. the ownership of the caller.
  409. If the trust level cannot be determined identity->comm_type is set
  410. to PEP_ct_unknown.
  411. ##### own_key_is_listed(String fpr, Bool⇑ listed)
  412. returns true id key is listed as own key
  413. ```
  414. parameters:
  415. fpr (in) fingerprint of key to test
  416. listed (out) flags if key is own
  417. ```
  418. ##### own_identities_retrieve(IdentityList⇑ own_identities)
  419. retrieve all own identities
  420. ```
  421. parameters:
  422. own_identities (out) list of own identities
  423. ```
  424. ##### set_own_key( Identity⇕ id, String fpr)
  425. mark key as own key
  426. ```
  427. parameters:
  428. me (inout) own identity this key is used for
  429. fpr (in) fingerprint of the key to mark as own key
  430. ```
  431. ##### undo_last_mistrust()
  432. reset identity and trust status for the last`identity in this session marked
  433. as mistrusted to their cached values from the time of mistrust
  434. ```
  435. parameters:
  436. (none)
  437. return value:
  438. PEP_STATUS_OK if identity and trust were successfully restored.
  439. Otherwise, error status from attempts to set.
  440. caveat:
  441. only works for this session, and only once. cache is invalidated
  442. upon use.
  443.   WILL NOT WORK ON MISTRUSTED OWN KEY
  444. ```
  445. ##### myself(Identity⇕ identity)
  446. ensures that the own identity is being complete
  447. ```
  448. parameters:
  449. identity (inout) identity of local user. At least .address, .username, .user_id must be set.
  450. return value:
  451. PEP_STATUS_OK if identity could be completed or was already complete, any other value on error
  452. caveat:
  453. This function generates a keypair on demand; because it's synchronous
  454. it can need a decent amount of time to return.
  455. If you need to do this asynchronous, you need to return an identity
  456. with retrieve_next_identity() where pEp_identity.me is true.
  457. ```
  458. ##### update_identity(Identity⇕)
  459. update identity information
  460. ```
  461. parameters:
  462. identity (inout) identity information of communication partner
  463. (identity->fpr is OUT ONLY)
  464. return value:
  465. PEP_STATUS_OK if identity could be updated,
  466. PEP_GET_KEY_FAILED for own identity that must be completed (myself())
  467. any other value on error
  468. caveat:
  469. if this function returns PEP_ct_unknown or PEP_ct_key_expired in
  470. identity->comm_type, the caller must insert the identity into the
  471. asynchronous management implementation, so retrieve_next_identity()
  472. will return this identity later
  473. at least identity->address must be a non-empty UTF-8 string as input
  474. update_identity() never writes flags; use set_identity_flags() for
  475. writing
  476. this function NEVER reads the incoming fpr, only writes to it.
  477. ```
  478. ##### trust_personal_key(Identity)
  479. mark a key as trusted with a person
  480. ```
  481. parameters:
  482. ident (in) person and key to trust in
  483. caveat:
  484. the fields user_id, address and fpr must be supplied
  485. ```
  486. ##### key_mistrusted(Identity)
  487. mark key as being compromized
  488. ```
  489. parameters:
  490. ident (in) person and key which was compromized
  491. ```
  492. ##### key_reset_trust(Identity)
  493. undo trust_personal_key and key_mistrusted() for keys we don't own
  494. ```
  495. parameters:
  496. ident (in) person and key which was compromized
  497. ```
  498. ##### least_trust(String fpr, PEP_comm_type⇑ comm_type)
  499. get the least known trust level for a key in the database
  500. ```
  501. parameters:
  502. fpr (in) fingerprint of key to check
  503. comm_type (out) least comm_type as result (out)
  504. ```
  505. If the trust level cannot be determined comm_type is set to PEP_ct_unknown.
  506. ##### get_key_rating(String fpr, PEP_comm_type⇑ comm_type)
  507. get the rating a bare key has
  508. ```
  509. parameters:
  510. fpr (in) unique identifyer for key as UTF-8 string
  511. comm_type (out) key rating
  512. ```
  513. Iif an error occurs, *comm_type is set to PEP_ct_unknown and an error is returned
  514. ##### renew_key(String fpr, Timestamp ts)
  515. renew an expired key
  516. ```
  517. parameters:
  518. fpr (in) ID of key to renew as UTF-8 string
  519. ts (in) timestamp when key should expire or NULL for default
  520. ```
  521. ##### revoke(String fpr, String reason)
  522. revoke a key
  523. ```
  524. parameters:
  525. fpr (in) ID of key to revoke as UTF-8 string
  526. reason (in) text with reason for revoke as UTF-8 string
  527. or NULL if reason unknown
  528. caveat:
  529. reason text must not include empty lines
  530. this function is meant for internal use only; better use
  531. key_mistrusted() of keymanagement API
  532. ```
  533. ##### key_expired(String fpr, Integer when, Bool⇑ expired)
  534. flags if a key is already expired
  535. ```
  536. parameters:
  537. fpr (in) ID of key to check as UTF-8 string
  538. when (in) UTC time of when should expiry be considered
  539. expired (out) flag if key expired
  540. ```
  541. #### from blacklist.h & OpenPGP_compat.h ####
  542. ##### blacklist_add(String fpr)
  543. add to blacklist
  544. * parameters: fpr (in) fingerprint of key to blacklist
  545. ##### blacklist_delete(String fpr)
  546. delete from blacklist
  547. * parameters: fpr (in) fingerprint of key to blacklist
  548. ##### blacklist_is_listed(String fpr, Bool⇑ listed)
  549. is_listed in blacklist
  550. ```
  551. parameters:
  552. session (in) session to use
  553. fpr (in) fingerprint of key to blacklist
  554. listted (out)
  555. ```
  556. ##### blacklist_retrieve(StringList⇑ blacklist)
  557. retrieve full blacklist of key fingerprints
  558. * parameters: blacklist (out) copy of blacklist
  559. ##### OpenPGP_list_keyinfo(String search_pattern, StringPairList⇑ keyinfo_list)
  560. get a key/UID list for pattern matches in keyring ("" to return entire keyring), filtering out revoked keys in the results
  561. ```
  562. parameters:
  563. search_pattern (in) search pattern - either an fpr, or something within the UID, or "" for all keys
  564. keyinfo_list (out) a key/value pair list for each key / UID combination
  565. ```
  566. #### Event Listener & Results ####
  567. ##### registerEventListener(String address, Integer port, String security_context)
  568. Register an address/port pair where a JSON-RPC call shall be made to, when the Engine wants to call the client application.
  569. These RPC calls are authenticated with a security_context parameter that is given to all calls (and can be different from the security_context
  570. that is used for calls from the client to the JSON Server Adapter).
  571. Currently there are two functions that can be called:
  572. * messageToSend( Message )
  573. * notifyHandshake( Identity self, Identity partner, sync_handshake_signal sig )
  574. ##### unregisterEventListener(String address, Integer port, String security_context)
  575. Unregister a previous registered JSON-RPC listener.
  576. ##### deliverHandshakeResult(Identity partner, PEP_sync_handshake_result result)
  577. give the result of the handshake dialog back to the Engine
  578. ```
  579. parameters:
  580. partner (in) the parther of the handshake
  581. result (in) handshake result
  582. ```
  583. #### Other ####
  584. ##### serverVersion()
  585. Returns a struct with SemVer-compatible ABI version, the codename of the
  586. JSON Adapter version etc.
  587. ##### version()
  588. Returns a codename for the current JSON Server Adapter's version.
  589. ##### getGpgEnvironment()
  590. Returns a struct holding 3 members
  591. * gnupg_path
  592. * gnupg_home environment variable, if set
  593. * gpg_agent_info environment variable, if set.
  594. ##### shutdown()
  595. shutdown the JSON Adapter