From bd6b3cdaf3a14dd31f2031301a10ec187eb92397 Mon Sep 17 00:00:00 2001 From: microshine Date: Tue, 30 Aug 2016 20:46:29 +0300 Subject: [PATCH 1/3] Add ERROR_STATE flag --- graphene-pk11/graphene-pk11.d.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/graphene-pk11/graphene-pk11.d.ts b/graphene-pk11/graphene-pk11.d.ts index 0405b4c6df..2a4d8aad0c 100644 --- a/graphene-pk11/graphene-pk11.d.ts +++ b/graphene-pk11/graphene-pk11.d.ts @@ -2131,6 +2131,7 @@ declare module "graphene-pk11" { SO_PIN_FINAL_TRY, SO_PIN_LOCKED, SO_PIN_TO_BE_CHANGED, + ERROR_STATE, } class Token extends HandleObject { From dda378990181cd75523afaddaf8d453c18e74276 Mon Sep 17 00:00:00 2001 From: microshine Date: Sat, 24 Sep 2016 16:18:53 +0300 Subject: [PATCH 2/3] Fix type errors --- pkcs11js/pkcs11js.d.ts | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/pkcs11js/pkcs11js.d.ts b/pkcs11js/pkcs11js.d.ts index dcbdb401cb..676dce6555 100644 --- a/pkcs11js/pkcs11js.d.ts +++ b/pkcs11js/pkcs11js.d.ts @@ -210,7 +210,7 @@ declare module "pkcs11js" { * @param {Handle} slot ID of token's slot * @returns {Handle[]} Gets mech. array */ - C_GetMechanismList(slot: Handle): number[]; + C_GetMechanismList(slot: Handle): Handle[]; /** * Obtains information about a particular mechanism possibly supported by a token * @@ -218,7 +218,7 @@ declare module "pkcs11js" { * @param {Handle} mech Type of mechanism * @returns {MechanismInfo} Receives mechanism info */ - C_GetMechanismInfo(slot: Handle, mech: number): MechanismInfo; + C_GetMechanismInfo(slot: Handle, mech: Handle): MechanismInfo; /* Session management */ @@ -1173,11 +1173,11 @@ declare module "pkcs11js" { const CKM_RSA_PKCS_TPM_1_1: number; const CKM_RSA_PKCS_OAEP_TPM_1_1: number; const CKM_VENDOR_DEFINED: number; - + // Session flags const CKF_RW_SESSION: number; const CKF_SERIAL_SESSION: number; - + // Follows const CKF_HW: number; const CKF_ENCRYPT: number; @@ -1192,6 +1192,7 @@ declare module "pkcs11js" { const CKF_WRAP: number; const CKF_UNWRAP: number; const CKF_DERIVE: number; + const CKF_CLOCK_ON_TOKEN: number; // Certificates const CKC_X_509: number; @@ -1223,4 +1224,4 @@ declare module "pkcs11js" { const CK_PARAMS_RSA_OAEP: number; const CK_PARAMS_RSA_PSS: number; const CK_PARAMS_EC_DH: number; -} \ No newline at end of file +} From 53a729cd0973d20549cf7bc320bc95932c7c0f7d Mon Sep 17 00:00:00 2001 From: microshine Date: Sun, 25 Sep 2016 01:33:59 +0300 Subject: [PATCH 3/3] Remove spaces --- pkcs11js/pkcs11js.d.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkcs11js/pkcs11js.d.ts b/pkcs11js/pkcs11js.d.ts index 676dce6555..d1b5314878 100644 --- a/pkcs11js/pkcs11js.d.ts +++ b/pkcs11js/pkcs11js.d.ts @@ -1173,11 +1173,11 @@ declare module "pkcs11js" { const CKM_RSA_PKCS_TPM_1_1: number; const CKM_RSA_PKCS_OAEP_TPM_1_1: number; const CKM_VENDOR_DEFINED: number; - + // Session flags const CKF_RW_SESSION: number; const CKF_SERIAL_SESSION: number; - + // Follows const CKF_HW: number; const CKF_ENCRYPT: number;