Module

XuDsigConst

Path

C:\CPRS\CPRS30\XuDigSig\XuDsigConst.pas

Last Modified

7/15/2014 3:26:44 PM

Units Used in Interface

Name Comments
wcrypt2 -

Constants

Name Declaration Scope Comments
ACTIVE_CLIENT 'ActivClient Cryptographic Service Provider' Interfaced Type 1
c_CRLlistname 'CRL_List.txt' Interfaced The CRL list file name
c_CRYPT_ALGID CALG_RC2 Interfaced Encryption algorithm to use
c_CSPname 'CSPName' Interfaced Get values CSPName and CSPType
c_CSPtype 'CSPType' Interfaced -
c_DsigPort 10265 Interfaced Port # to listen on
c_ENCODING_TYPE PKCS_7_ASN_ENCODING or X509_ASN_ENCODING Interfaced Encodeing types
c_HASH_ALGID CALG_SHA_256 Interfaced
CHASH_ALGID = CALG_MD5; // Hash algorithm to use
cHASH_ALGID = CALG_SHA; // Hash algorithm to use

 Hash algorithm to use
c_KEY_FLAGS CRYPT_EXPORTABLE or CRYPT_CREATE_SALT or CRYPT_USER_PROTECTED Interfaced Key flags
c_RecordFile c_tempFilePath + 'CRL_Record.txt' Interfaced The File to Record events
c_RecordMax 250 Interfaced The Max number of records in the Record file.
c_SignPROV_NAME MS_ENH_RSA_AES_PROV_XP_A Interfaced
Use MS for test until get PIV card
 JLI 120209
    c_SignPROV_NAME = ACTIVE_CLIENT;  //Signing provider
    c_SignPROV_type = 1;              //Must match  ^
JLI 120209  replaced by following 

Signing provider
c_SignPROV_type 24 Interfaced Must match ^
c_SignRegKey '\SOFTWARE\Vista\CSP' Interfaced Registry Key to check for SmartCard provider / Provider name
c_stoFilename 'crlstore.sto' Interfaced The CRL Store file name
c_stoFilePath 'C:\PROGRAM FILES\VISTA\CRYPTOAPI\' Interfaced The path to the CRL store file
c_tempFileName 'CRLtemp.crl' Interfaced The CRL temp file name
c_tempFilePath 'c:\temp\' Interfaced The path for Temporary files.
c_VerPROV_NAME MS_ENH_RSA_AES_PROV_XP_A Interfaced
End of
Signing provider

Verifing Provider
c_VerPROV_type 24 Interfaced Must match ^
cCRLF #13#10 Interfaced To add a CR/LF to strings
cDEAactivity '2.16.840.1.101.3.5.5' Interfaced -
cDEAname '2.16.840.1.101.3.5.2' Interfaced -
cDEAnumber '2.16.840.1.101.3.5.3' Interfaced -
cDEApostal '2.16.840.1.101.3.5.6' Interfaced -
cDEAsch2 $40 Interfaced
The DEA Schedule Bit string
The bitstring for schedule from the Cert.
 0 1 1 1 1 1 1 0
             |- 5
           |- 4
         |- 3N
       |- 3
     |- 2N
   |- 2
cDEAsch2n $20 Interfaced -
cDEAsch3 $10 Interfaced -
cDEAsch3n $08 Interfaced -
cDEAsch4 $04 Interfaced -
cDEAsch5 $02 Interfaced -
cDEAschedule '2.16.840.1.101.3.5.4' Interfaced -
cDEAversion '2.16.840.1.101.3.5.1' Interfaced The DEA Final OID's
cProv_1 'Passage Enhanced Cryptographic Provider' Interfaced -
cProv_2 'ActivCard Gold Cryptographic Service Provider' Interfaced -
cSep '$' Interfaced The DEA item separator. Used in Address and Drug Schedule
MS_ENH_RSA_AES_PROV_XP_A 'Microsoft Enhanced RSA and AES Cryptographic Provider' Interfaced
MS_ENH_RSA_AES_PROV_XP_A = 'Microsoft Enhanced RSA and AES Cryptographic Provider (Prototype)';  //type 24

 (Prototype)';  //type 24
SCARD_S_SUCCESS 0 Interfaced SmartCard reader interface


Module Source

1     unit XuDsigConst;
2     
3     interface
4     
5     uses  wcrypt2;
6     
7     const
8         //cHASH_ALGID = CALG_MD5; // Hash algorithm to use
9         //cHASH_ALGID = CALG_SHA; // Hash algorithm to use
10        c_HASH_ALGID = CALG_SHA_256; // Hash algorithm to use
11        c_CRYPT_ALGID = CALG_RC2; // Encryption algorithm to use
12        // Key flags
13        c_KEY_FLAGS = CRYPT_EXPORTABLE or CRYPT_CREATE_SALT or CRYPT_USER_PROTECTED;
14        //Encodeing types
15        c_ENCODING_TYPE = PKCS_7_ASN_ENCODING or X509_ASN_ENCODING;
16        //To add a CR/LF to strings
17        cCRLF = #13#10;
18    //    MS_ENH_RSA_AES_PROV_XP_A = 'Microsoft Enhanced RSA and AES Cryptographic Provider (Prototype)';  //type 24
19        MS_ENH_RSA_AES_PROV_XP_A = 'Microsoft Enhanced RSA and AES Cryptographic Provider';// (Prototype)';  //type 24
20        ACTIVE_CLIENT = 'ActivClient Cryptographic Service Provider';    //type 1
21        //Use MS for test until get PIV card
22    { JLI 120209
23        c_SignPROV_NAME = ACTIVE_CLIENT;  //Signing provider
24        c_SignPROV_type = 1;              //Must match  ^
25    JLI 120209  replaced by following }
26        c_SignPROV_NAME = MS_ENH_RSA_AES_PROV_XP_A;  //Signing provider
27        c_SignPROV_type = 24;              //Must match  ^
28    // end of
29      //Signing provider
30        c_VerPROV_NAME = MS_ENH_RSA_AES_PROV_XP_A;    //Verifing Provider
31        c_VerPROV_type = 24;                           //Must match ^
32        //Port # to listen on
33        c_DsigPort = 10265;
34    
35        //Registry Key to check for SmartCard provider / Provider name
36        c_SignRegKey = '\SOFTWARE\Vista\CSP';
37        //get values CSPName and CSPType
38        const c_CSPname = 'CSPName';
39        const c_CSPtype = 'CSPType';
40        
41        cProv_1 = 'Passage Enhanced Cryptographic Provider';
42        cProv_2 = 'ActivCard Gold Cryptographic Service Provider';
43    
44        //The path to the CRL store file
45        c_stoFilePath = 'C:\PROGRAM FILES\VISTA\CRYPTOAPI\';
46        //The CRL Store file name
47        c_stoFilename = 'crlstore.sto';
48        //The path for Temporary files.
49        c_tempFilePath = 'c:\temp\';
50        //The CRL temp file name
51        c_tempFileName = 'CRLtemp.crl';
52        //The CRL list file name
53        c_CRLlistname = 'CRL_List.txt';
54        //The File to Record events
55        c_RecordFile = c_tempFilePath + 'CRL_Record.txt';
56        //The Max number of records in the Record file.
57        c_RecordMax = 250;
58        //SmartCard reader interface
59        SCARD_S_SUCCESS = 0;
60    
61        //The DEA item separator. Used in Address and Drug Schedule
62        cSep = '$';
63        //The DEA Final OID's
64        cDEAversion =  '2.16.840.1.101.3.5.1';
65        cDEAname =     '2.16.840.1.101.3.5.2';
66        cDEAnumber =   '2.16.840.1.101.3.5.3';
67        cDEAschedule = '2.16.840.1.101.3.5.4';
68        cDEAactivity = '2.16.840.1.101.3.5.5';
69        cDEApostal =   '2.16.840.1.101.3.5.6';
70    
71        //The DEA Schedule Bit string
72        //The bitstring for schedule from the Cert.
73        // 0 1 1 1 1 1 1 0
74        //             |- 5
75        //           |- 4
76        //         |- 3N
77        //       |- 3
78        //     |- 2N
79        //   |- 2
80    
81        cDEAsch2 = $40;
82        cDEAsch2n = $20;
83        cDEAsch3  = $10;
84        cDEAsch3n = $08;
85        cDEAsch4  = $04;
86        cDEAsch5  = $02;
87    
88    implementation
89    
90    
91    end.

Module Calls (2 levels)


XuDsigConst
 └wcrypt2

Module Called-By (2 levels)


    XuDsigConst
      XuDsigS┘ 
    uOrders┤   
     fFrame┤   
fOrdersSign┤   
    fReview┘