@keetanetwork/anchor 0.0.12 → 0.0.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/certificates.d.ts +83 -21
- package/lib/certificates.d.ts.map +1 -1
- package/lib/certificates.generated.d.ts +3 -0
- package/lib/certificates.generated.d.ts.map +1 -0
- package/lib/certificates.generated.js +120 -0
- package/lib/certificates.generated.js.map +1 -0
- package/lib/certificates.js +579 -117
- package/lib/certificates.js.map +1 -1
- package/lib/http-server.d.ts +2 -1
- package/lib/http-server.d.ts.map +1 -1
- package/lib/http-server.js +4 -4
- package/lib/http-server.js.map +1 -1
- package/lib/resolver.d.ts +2 -1
- package/lib/resolver.d.ts.map +1 -1
- package/lib/resolver.js.map +1 -1
- package/lib/utils/asn1.d.ts +2 -1
- package/lib/utils/asn1.d.ts.map +1 -1
- package/lib/utils/asn1.js.map +1 -1
- package/lib/utils/buffer.d.ts +3 -0
- package/lib/utils/buffer.d.ts.map +1 -1
- package/lib/utils/buffer.js +26 -0
- package/lib/utils/buffer.js.map +1 -1
- package/lib/utils/guards.d.ts +14 -0
- package/lib/utils/guards.d.ts.map +1 -0
- package/lib/utils/guards.js +31 -0
- package/lib/utils/guards.js.map +1 -0
- package/lib/utils/index.d.ts +3 -1
- package/lib/utils/index.d.ts.map +1 -1
- package/lib/utils/index.js +3 -1
- package/lib/utils/index.js.map +1 -1
- package/lib/utils/json.d.ts +2 -2
- package/lib/utils/json.d.ts.map +1 -1
- package/lib/utils/json.js.map +1 -1
- package/lib/utils/oid.d.ts +7 -0
- package/lib/utils/oid.d.ts.map +1 -0
- package/lib/utils/oid.js +22 -0
- package/lib/utils/oid.js.map +1 -0
- package/lib/utils/signing.d.ts.map +1 -1
- package/lib/utils/signing.js +26 -2
- package/lib/utils/signing.js.map +1 -1
- package/npm-shrinkwrap.json +2 -8
- package/package.json +1 -2
- package/services/fx/client.d.ts +1 -0
- package/services/fx/client.d.ts.map +1 -1
- package/services/fx/client.js +72 -72
- package/services/fx/client.js.map +1 -1
- package/services/fx/common.d.ts +23 -14
- package/services/fx/common.d.ts.map +1 -1
- package/services/fx/common.js +177 -1
- package/services/fx/common.js.map +1 -1
- package/services/fx/server.d.ts +13 -4
- package/services/fx/server.d.ts.map +1 -1
- package/services/fx/server.js +58 -151
- package/services/fx/server.js.map +1 -1
- package/services/kyc/client.d.ts.map +1 -1
- package/services/kyc/client.js +1 -8
- package/services/kyc/client.js.map +1 -1
- package/services/kyc/common.d.ts +39 -3
- package/services/kyc/common.d.ts.map +1 -1
- package/services/kyc/common.generated.d.ts +5 -0
- package/services/kyc/common.generated.d.ts.map +1 -0
- package/services/kyc/common.generated.js +241 -0
- package/services/kyc/common.generated.js.map +1 -0
- package/services/kyc/common.js +68 -1
- package/services/kyc/common.js.map +1 -1
- package/services/kyc/iso20022.generated.d.ts +285 -0
- package/services/kyc/iso20022.generated.d.ts.map +1 -0
- package/services/kyc/iso20022.generated.js +205 -0
- package/services/kyc/iso20022.generated.js.map +1 -0
- package/services/kyc/oids.generated.d.ts +83 -0
- package/services/kyc/oids.generated.d.ts.map +1 -0
- package/services/kyc/oids.generated.js +130 -0
- package/services/kyc/oids.generated.js.map +1 -0
- package/services/kyc/server.d.ts +141 -0
- package/services/kyc/server.d.ts.map +1 -0
- package/services/kyc/server.js +183 -0
- package/services/kyc/server.js.map +1 -0
- package/services/kyc/utils/generate-kyc-schema.d.ts +3 -0
- package/services/kyc/utils/generate-kyc-schema.d.ts.map +1 -0
- package/services/kyc/utils/generate-kyc-schema.js +1154 -0
- package/services/kyc/utils/generate-kyc-schema.js.map +1 -0
|
@@ -0,0 +1,285 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Generated ISO20022 Type Definitions
|
|
3
|
+
* This file is auto-generated from oids.json.
|
|
4
|
+
*/
|
|
5
|
+
import * as ASN1 from '../../lib/utils/asn1.js';
|
|
6
|
+
/** Country code or name */
|
|
7
|
+
/** OID: 1.3.6.1.4.1.62675.1.2.0 */
|
|
8
|
+
export type Country = string;
|
|
9
|
+
/** Country subdivision (state/province) */
|
|
10
|
+
/** OID: 1.3.6.1.4.1.62675.1.2.1 */
|
|
11
|
+
export type CountrySubDivision = string;
|
|
12
|
+
/** Postal code */
|
|
13
|
+
/** OID: 1.3.6.1.4.1.62675.1.2.3 */
|
|
14
|
+
export type PostalCode = string;
|
|
15
|
+
/** Town or city name */
|
|
16
|
+
/** OID: 1.3.6.1.4.1.62675.1.2.4 */
|
|
17
|
+
export type TownName = string;
|
|
18
|
+
/** Building number */
|
|
19
|
+
/** OID: 1.3.6.1.4.1.62675.1.2.5 */
|
|
20
|
+
export type BuildingNumber = string;
|
|
21
|
+
/** Street name */
|
|
22
|
+
/** OID: 1.3.6.1.4.1.62675.1.2.6 */
|
|
23
|
+
export type StreetName = string;
|
|
24
|
+
/** Free-form address lines */
|
|
25
|
+
/** OID: 1.3.6.1.4.1.62675.1.2.7 */
|
|
26
|
+
export type AddressLines = string[];
|
|
27
|
+
/** Sub-department */
|
|
28
|
+
/** OID: 1.3.6.1.4.1.62675.1.2.8 */
|
|
29
|
+
export type SubDepartment = string;
|
|
30
|
+
/** Department */
|
|
31
|
+
/** OID: 1.3.6.1.4.1.62675.1.2.9 */
|
|
32
|
+
export type Department = string;
|
|
33
|
+
/** Purpose of email address */
|
|
34
|
+
/** OID: 1.3.6.1.4.1.62675.1.3.0 */
|
|
35
|
+
export type EmailAddressPurpose = string;
|
|
36
|
+
/** Name prefix code */
|
|
37
|
+
/** OID: 1.3.6.1.4.1.62675.1.0.0 */
|
|
38
|
+
export type NamePrefixCode = 'DOCT' | 'MIST' | 'MISS' | 'MIKS' | 'MME';
|
|
39
|
+
/** Preferred contact method */
|
|
40
|
+
/** OID: 1.3.6.1.4.1.62675.1.9.0 */
|
|
41
|
+
export type PreferredContactMethodCode = 'LETT' | 'MAIL' | 'PHON' | 'FAXX' | 'CELL';
|
|
42
|
+
/** Address type classification */
|
|
43
|
+
/** OID: 1.3.6.1.4.1.62675.1.2.10 */
|
|
44
|
+
export type AddressType = string;
|
|
45
|
+
/** Organization identification scheme name */
|
|
46
|
+
/** OID: 1.3.6.1.4.1.62675.1.8.0.2 */
|
|
47
|
+
export type OrganizationIdentificationSchemeNameChoice = string;
|
|
48
|
+
/** Person identification scheme name */
|
|
49
|
+
/** OID: 1.3.6.1.4.1.62675.1.8.1.1 */
|
|
50
|
+
export type PersonIdentificationSchemeNameChoice = string;
|
|
51
|
+
/** Generic organization identification */
|
|
52
|
+
/** OID: 1.3.6.1.4.1.62675.1.8.0.1 */
|
|
53
|
+
export interface GenericOrganizationIdentification {
|
|
54
|
+
id: Id;
|
|
55
|
+
schemeName?: OrganizationIdentificationSchemeNameChoice;
|
|
56
|
+
issuer?: Issuer;
|
|
57
|
+
}
|
|
58
|
+
export interface OrganizationIdentificationBicChoice {
|
|
59
|
+
tag: 0;
|
|
60
|
+
name: 'bic';
|
|
61
|
+
value: string;
|
|
62
|
+
}
|
|
63
|
+
export interface OrganizationIdentificationLeiChoice {
|
|
64
|
+
tag: 1;
|
|
65
|
+
name: 'lei';
|
|
66
|
+
value: string;
|
|
67
|
+
}
|
|
68
|
+
export interface OrganizationIdentificationOtherChoice {
|
|
69
|
+
tag: 2;
|
|
70
|
+
name: 'other';
|
|
71
|
+
value: GenericOrganizationIdentification[];
|
|
72
|
+
}
|
|
73
|
+
export type OrganizationIdentificationChoice = OrganizationIdentificationBicChoice | OrganizationIdentificationLeiChoice | OrganizationIdentificationOtherChoice;
|
|
74
|
+
export type OrganizationIdentification = OrganizationIdentificationChoice[];
|
|
75
|
+
export declare const OrganizationIdentificationSchema: ASN1.Schema;
|
|
76
|
+
export declare const OrganizationIdentificationFields: readonly ["bic", "lei", "other"];
|
|
77
|
+
/** Generic person identification */
|
|
78
|
+
/** OID: 1.3.6.1.4.1.62675.1.8.1.0 */
|
|
79
|
+
export interface GenericPersonIdentification {
|
|
80
|
+
id: Id;
|
|
81
|
+
schemeName?: PersonIdentificationSchemeNameChoice;
|
|
82
|
+
issuer?: Issuer;
|
|
83
|
+
}
|
|
84
|
+
export interface PersonIdentificationDateAndPlaceOfBirthChoice {
|
|
85
|
+
tag: 0;
|
|
86
|
+
name: 'dateAndPlaceOfBirth';
|
|
87
|
+
value: DateAndPlaceOfBirth;
|
|
88
|
+
}
|
|
89
|
+
export interface PersonIdentificationOtherChoice {
|
|
90
|
+
tag: 1;
|
|
91
|
+
name: 'other';
|
|
92
|
+
value: GenericPersonIdentification[];
|
|
93
|
+
}
|
|
94
|
+
export type PersonIdentificationChoice = PersonIdentificationDateAndPlaceOfBirthChoice | PersonIdentificationOtherChoice;
|
|
95
|
+
export type PersonIdentification = PersonIdentificationChoice[];
|
|
96
|
+
export declare const PersonIdentificationSchema: ASN1.Schema;
|
|
97
|
+
export declare const PersonIdentificationFields: readonly ["dateAndPlaceOfBirth", "other"];
|
|
98
|
+
/** Other contact method */
|
|
99
|
+
/** OID: 1.3.6.1.4.1.62675.1.9.1 */
|
|
100
|
+
export interface OtherContact {
|
|
101
|
+
id?: Id;
|
|
102
|
+
channelType: string;
|
|
103
|
+
}
|
|
104
|
+
/** ASN.1 schema for AddressType */
|
|
105
|
+
export declare const AddressTypeSchema: ASN1.Schema;
|
|
106
|
+
/** ASN.1 schema for OrganizationIdentificationSchemeNameChoice */
|
|
107
|
+
export declare const OrganizationIdentificationSchemeNameChoiceSchema: ASN1.Schema;
|
|
108
|
+
/** ASN.1 schema for PersonIdentificationSchemeNameChoice */
|
|
109
|
+
export declare const PersonIdentificationSchemeNameChoiceSchema: ASN1.Schema;
|
|
110
|
+
/** ASN.1 schema for GenericOrganizationIdentification */
|
|
111
|
+
export declare const GenericOrganizationIdentificationSchema: ASN1.Schema;
|
|
112
|
+
/** ASN.1 schema for GenericPersonIdentification */
|
|
113
|
+
export declare const GenericPersonIdentificationSchema: ASN1.Schema;
|
|
114
|
+
/** ASN.1 schema for OtherContact */
|
|
115
|
+
export declare const OtherContactSchema: ASN1.Schema;
|
|
116
|
+
/** ASN.1 schema for EntityType */
|
|
117
|
+
export declare const EntityTypeSchema: ASN1.Schema;
|
|
118
|
+
/** Person's full name */
|
|
119
|
+
/** OID: 1.3.6.1.4.1.62675.1.0 */
|
|
120
|
+
export type FullName = string;
|
|
121
|
+
/** Person's first name */
|
|
122
|
+
/** OID: 1.3.6.1.4.1.62675.1.0.1 */
|
|
123
|
+
export type FirstName = string;
|
|
124
|
+
/** Person's last name */
|
|
125
|
+
/** OID: 1.3.6.1.4.1.62675.1.0.2 */
|
|
126
|
+
export type LastName = string;
|
|
127
|
+
/** Person's middle name */
|
|
128
|
+
/** OID: 1.3.6.1.4.1.62675.1.0.3 */
|
|
129
|
+
export type MiddleName = string;
|
|
130
|
+
/** Date of birth */
|
|
131
|
+
/** OID: 1.3.6.1.4.1.62675.1.1 */
|
|
132
|
+
export type DateOfBirth = Date;
|
|
133
|
+
/** Physical address */
|
|
134
|
+
/** OID: 1.3.6.1.4.1.62675.1.2 */
|
|
135
|
+
export interface Address {
|
|
136
|
+
addressType?: AddressType;
|
|
137
|
+
department?: Department;
|
|
138
|
+
subDepartment?: SubDepartment;
|
|
139
|
+
streetName?: StreetName;
|
|
140
|
+
buildingNumber?: BuildingNumber;
|
|
141
|
+
postalCode?: PostalCode;
|
|
142
|
+
townName?: TownName;
|
|
143
|
+
countrySubDivision?: CountrySubDivision;
|
|
144
|
+
country?: Country;
|
|
145
|
+
addressLines?: AddressLines;
|
|
146
|
+
}
|
|
147
|
+
/** Email address */
|
|
148
|
+
/** OID: 1.3.6.1.4.1.62675.1.3 */
|
|
149
|
+
export type Email = string;
|
|
150
|
+
/** Phone number */
|
|
151
|
+
/** OID: 1.3.6.1.4.1.62675.1.4 */
|
|
152
|
+
export type PhoneNumber = string;
|
|
153
|
+
/** Date and place of birth information */
|
|
154
|
+
/** OID: 1.3.6.1.4.1.62675.1.5 */
|
|
155
|
+
export interface DateAndPlaceOfBirth {
|
|
156
|
+
birthDate: BirthDate;
|
|
157
|
+
provinceOfBirth?: CountrySubDivision;
|
|
158
|
+
cityOfBirth: TownName;
|
|
159
|
+
countryOfBirth: Country;
|
|
160
|
+
}
|
|
161
|
+
/** Job title */
|
|
162
|
+
/** OID: 1.3.6.1.4.1.62675.1.6 */
|
|
163
|
+
export type JobTitle = string;
|
|
164
|
+
/** Job responsibility */
|
|
165
|
+
/** OID: 1.3.6.1.4.1.62675.1.6.1 */
|
|
166
|
+
export type JobResponsibility = string;
|
|
167
|
+
/** Identifier */
|
|
168
|
+
/** OID: 1.3.6.1.4.1.62675.1.7 */
|
|
169
|
+
export type Id = string;
|
|
170
|
+
/** Issuer identifier */
|
|
171
|
+
/** OID: 1.3.6.1.4.1.62675.1.7.1 */
|
|
172
|
+
export type Issuer = string;
|
|
173
|
+
/** Entity type (organization or person) */
|
|
174
|
+
/** OID: 1.3.6.1.4.1.62675.1.8 */
|
|
175
|
+
export type EntityType = OrganizationIdentification | PersonIdentification;
|
|
176
|
+
/** Contact details */
|
|
177
|
+
/** OID: 1.3.6.1.4.1.62675.1.9 */
|
|
178
|
+
export interface ContactDetails {
|
|
179
|
+
namePrefix?: NamePrefixCode;
|
|
180
|
+
fullName?: FullName;
|
|
181
|
+
phoneNumber?: PhoneNumber;
|
|
182
|
+
mobileNumber?: PhoneNumber;
|
|
183
|
+
faxNumber?: PhoneNumber;
|
|
184
|
+
emailAddress?: EmailAddress;
|
|
185
|
+
emailPurpose?: EmailAddressPurpose;
|
|
186
|
+
jobTitle?: JobTitle;
|
|
187
|
+
jobResponsibility?: JobResponsibility;
|
|
188
|
+
department?: Department;
|
|
189
|
+
other?: OtherContact[];
|
|
190
|
+
preferredMethod?: PreferredContactMethodCode;
|
|
191
|
+
}
|
|
192
|
+
/** Nationality */
|
|
193
|
+
/** OID: 1.3.6.1.4.1.62675.1.10 */
|
|
194
|
+
export type Nationality = string;
|
|
195
|
+
/** Document information */
|
|
196
|
+
/** OID: 1.3.6.1.4.1.62675.1.11 */
|
|
197
|
+
export interface Document {
|
|
198
|
+
type: string;
|
|
199
|
+
number?: string;
|
|
200
|
+
issuer?: Issuer;
|
|
201
|
+
issueDate?: Date;
|
|
202
|
+
expiryDate?: Date;
|
|
203
|
+
issuingCountry?: Country;
|
|
204
|
+
attachmentUrl?: string;
|
|
205
|
+
}
|
|
206
|
+
/** Driver's license front side document */
|
|
207
|
+
/** OID: 1.3.6.1.4.1.62675.1.11.0 */
|
|
208
|
+
export type DocumentDriversLicenseFront = Document;
|
|
209
|
+
/** Driver's license back side document */
|
|
210
|
+
/** OID: 1.3.6.1.4.1.62675.1.11.1 */
|
|
211
|
+
export type DocumentDriversLicenseBack = Document;
|
|
212
|
+
/** Passport document */
|
|
213
|
+
/** OID: 1.3.6.1.4.1.62675.1.11.2 */
|
|
214
|
+
export type DocumentPassport = Document;
|
|
215
|
+
/** Alias for DateOfBirth */
|
|
216
|
+
export type BirthDate = DateOfBirth;
|
|
217
|
+
/** Alias for Email */
|
|
218
|
+
export type EmailAddress = Email;
|
|
219
|
+
/** Union type of all sensitive attribute types */
|
|
220
|
+
export type SensitiveAttributeType = FullName | FirstName | LastName | MiddleName | DateOfBirth | Address | Email | PhoneNumber | DateAndPlaceOfBirth | JobTitle | JobResponsibility | Id | Issuer | EntityType | ContactDetails | Nationality | Document | DocumentDriversLicenseFront | DocumentDriversLicenseBack | DocumentPassport;
|
|
221
|
+
/** Map of attribute name to acceptable input type for CertificateBuilder.setAttribute */
|
|
222
|
+
export interface CertificateAttributeValueMap {
|
|
223
|
+
'fullName': FullName;
|
|
224
|
+
'firstName': FirstName;
|
|
225
|
+
'lastName': LastName;
|
|
226
|
+
'middleName': MiddleName;
|
|
227
|
+
'dateOfBirth': DateOfBirth;
|
|
228
|
+
'address': Address;
|
|
229
|
+
'email': Email;
|
|
230
|
+
'phoneNumber': PhoneNumber;
|
|
231
|
+
'dateAndPlaceOfBirth': DateAndPlaceOfBirth;
|
|
232
|
+
'jobTitle': JobTitle;
|
|
233
|
+
'jobResponsibility': JobResponsibility;
|
|
234
|
+
'id': Id;
|
|
235
|
+
'issuer': Issuer;
|
|
236
|
+
'entityType': EntityType;
|
|
237
|
+
'contactDetails': ContactDetails;
|
|
238
|
+
'nationality': Nationality;
|
|
239
|
+
'document': Document;
|
|
240
|
+
'documentDriversLicenseFront': DocumentDriversLicenseFront;
|
|
241
|
+
'documentDriversLicenseBack': DocumentDriversLicenseBack;
|
|
242
|
+
'documentPassport': DocumentPassport;
|
|
243
|
+
}
|
|
244
|
+
/** Helper generic to get attribute value type by name */
|
|
245
|
+
export type CertificateAttributeValue<Name extends keyof CertificateAttributeValueMap> = CertificateAttributeValueMap[Name];
|
|
246
|
+
export declare const AddressFields: readonly ["addressLines", "addressType", "buildingNumber", "country", "countrySubDivision", "department", "postalCode", "streetName", "subDepartment", "townName"];
|
|
247
|
+
export declare const AddressSchema: ASN1.Schema;
|
|
248
|
+
export declare const DateAndPlaceOfBirthFields: readonly ["birthDate", "cityOfBirth", "countryOfBirth", "provinceOfBirth"];
|
|
249
|
+
export declare const DateAndPlaceOfBirthSchema: ASN1.Schema;
|
|
250
|
+
export declare const ContactDetailsFields: readonly ["department", "emailAddress", "emailPurpose", "faxNumber", "fullName", "jobResponsibility", "jobTitle", "mobileNumber", "namePrefix", "other", "phoneNumber", "preferredMethod"];
|
|
251
|
+
export declare const ContactDetailsSchema: ASN1.Schema;
|
|
252
|
+
export declare const DocumentFields: readonly ["type", "number", "issuer", "issueDate", "expiryDate", "issuingCountry", "attachmentUrl"];
|
|
253
|
+
export declare const DocumentSchema: ASN1.Schema;
|
|
254
|
+
export declare const CertificateAttributeOIDDB: {
|
|
255
|
+
readonly fullName: "1.3.6.1.4.1.62675.1.0";
|
|
256
|
+
readonly firstName: "1.3.6.1.4.1.62675.1.0.1";
|
|
257
|
+
readonly lastName: "1.3.6.1.4.1.62675.1.0.2";
|
|
258
|
+
readonly middleName: "1.3.6.1.4.1.62675.1.0.3";
|
|
259
|
+
readonly dateOfBirth: "1.3.6.1.4.1.62675.1.1";
|
|
260
|
+
readonly address: "1.3.6.1.4.1.62675.1.2";
|
|
261
|
+
readonly email: "1.3.6.1.4.1.62675.1.3";
|
|
262
|
+
readonly phoneNumber: "1.3.6.1.4.1.62675.1.4";
|
|
263
|
+
readonly dateAndPlaceOfBirth: "1.3.6.1.4.1.62675.1.5";
|
|
264
|
+
readonly jobTitle: "1.3.6.1.4.1.62675.1.6";
|
|
265
|
+
readonly jobResponsibility: "1.3.6.1.4.1.62675.1.6.1";
|
|
266
|
+
readonly id: "1.3.6.1.4.1.62675.1.7";
|
|
267
|
+
readonly issuer: "1.3.6.1.4.1.62675.1.7.1";
|
|
268
|
+
readonly entityType: "1.3.6.1.4.1.62675.1.8";
|
|
269
|
+
readonly contactDetails: "1.3.6.1.4.1.62675.1.9";
|
|
270
|
+
readonly nationality: "1.3.6.1.4.1.62675.1.10";
|
|
271
|
+
readonly document: "1.3.6.1.4.1.62675.1.11";
|
|
272
|
+
readonly documentDriversLicenseFront: "1.3.6.1.4.1.62675.1.11.0";
|
|
273
|
+
readonly documentDriversLicenseBack: "1.3.6.1.4.1.62675.1.11.1";
|
|
274
|
+
readonly documentPassport: "1.3.6.1.4.1.62675.1.11.2";
|
|
275
|
+
};
|
|
276
|
+
export declare const SENSITIVE_CERTIFICATE_ATTRIBUTES: readonly ["fullName", "firstName", "lastName", "middleName", "dateOfBirth", "address", "email", "phoneNumber", "dateAndPlaceOfBirth", "jobTitle", "jobResponsibility", "id", "issuer", "entityType", "contactDetails", "nationality", "document", "documentDriversLicenseFront", "documentDriversLicenseBack", "documentPassport"];
|
|
277
|
+
export type SensitiveCertificateAttributeNames = typeof SENSITIVE_CERTIFICATE_ATTRIBUTES[number];
|
|
278
|
+
export declare const SensitiveCertificateAttributeNames: readonly ["FullName", "FirstName", "LastName", "MiddleName", "DateOfBirth", "Address", "Email", "PhoneNumber", "DateAndPlaceOfBirth", "JobTitle", "JobResponsibility", "Id", "Issuer", "EntityType", "ContactDetails", "Nationality", "Document", "DocumentDriversLicenseFront", "DocumentDriversLicenseBack", "DocumentPassport"];
|
|
279
|
+
export declare const CertificateAttributeFieldNames: {
|
|
280
|
+
readonly [K in keyof typeof CertificateAttributeOIDDB]?: readonly string[];
|
|
281
|
+
};
|
|
282
|
+
export declare const CertificateAttributeSchema: {
|
|
283
|
+
readonly [K in keyof typeof CertificateAttributeOIDDB]: ASN1.Schema;
|
|
284
|
+
};
|
|
285
|
+
//# sourceMappingURL=iso20022.generated.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"iso20022.generated.d.ts","sourceRoot":"","sources":["../../../src/services/kyc/iso20022.generated.ts"],"names":[],"mappings":"AACA;;;GAGG;AAEH,OAAO,KAAK,IAAI,MAAM,yBAAyB,CAAC;AAGhD,2BAA2B;AAC3B,mCAAmC;AACnC,MAAM,MAAM,OAAO,GAAG,MAAM,CAAC;AAE7B,2CAA2C;AAC3C,mCAAmC;AACnC,MAAM,MAAM,kBAAkB,GAAG,MAAM,CAAC;AAExC,kBAAkB;AAClB,mCAAmC;AACnC,MAAM,MAAM,UAAU,GAAG,MAAM,CAAC;AAEhC,wBAAwB;AACxB,mCAAmC;AACnC,MAAM,MAAM,QAAQ,GAAG,MAAM,CAAC;AAE9B,sBAAsB;AACtB,mCAAmC;AACnC,MAAM,MAAM,cAAc,GAAG,MAAM,CAAC;AAEpC,kBAAkB;AAClB,mCAAmC;AACnC,MAAM,MAAM,UAAU,GAAG,MAAM,CAAC;AAEhC,8BAA8B;AAC9B,mCAAmC;AACnC,MAAM,MAAM,YAAY,GAAG,MAAM,EAAE,CAAC;AAEpC,qBAAqB;AACrB,mCAAmC;AACnC,MAAM,MAAM,aAAa,GAAG,MAAM,CAAC;AAEnC,iBAAiB;AACjB,mCAAmC;AACnC,MAAM,MAAM,UAAU,GAAG,MAAM,CAAC;AAEhC,+BAA+B;AAC/B,mCAAmC;AACnC,MAAM,MAAM,mBAAmB,GAAG,MAAM,CAAC;AAGzC,uBAAuB;AACvB,mCAAmC;AACnC,MAA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zD,kBAAkB,EAAE,gBAAgB,CAAC;CACrC;AAED,yDAAyD;AACzD,MAAM,MAAM,yBAAyB,CAAC,IAAI,SAAS,MAAM,4BAA4B,IAAI,4BAA4B,CAAC,IAAI,CAAC,CAAC;AAE5H,eAAO,MAAM,aAAa,oKAAqK,CAAC;AAChM,eAAO,MAAM,aAAa,EAAE,IAAI,CAAC,MAWD,CAAC;AACjC,eAAO,MAAM,yBAAyB,4EAA6E,CAAC;AACpH,eAAO,MAAM,yBAAyB,EAAE,IAAI,CAAC,MAKb,CAAC;AACjC,eAAO,MAAM,oBAAoB,4LAA6L,CAAC;AAC/N,eAAO,MAAM,oBAAoB,EAAE,IAAI,CAAC,MAaR,CAAC;AACjC,eAAO,MAAM,cAAc,qGAAsG,CAAC;AAClI,eAAO,MAAM,cAAc,EAAE,IAAI,CAAC,MAQF,CAAC;AACjC,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;;;;;;CAqB5B,CAAC;AAEX,eAAO,MAAM,gCAAgC,oUAqBnC,CAAC;AAEX,MAAM,MAAM,kCAAkC,GAAG,OAAO,gCAAgC,CAAC,MAAM,CAAC,CAAC;AAEjG,eAAO,MAAM,kCAAkC,oUAqBrC,CAAC;AAEX,eAAO,MAAM,8BAA8B,EAAE;IAAE,QAAQ,EAAE,CAAC,IAAI,MAAM,OAAO,yBAAyB,CAAC,CAAC,EAAE,SAAS,MAAM,EAAE;CAK/G,CAAC;AAEX,eAAO,MAAM,0BAA0B,EAAE;IAAE,QAAQ,EAAE,CAAC,IAAI,MAAM,OAAO,yBAAyB,GAAG,IAAI,CAAC,MAAM;CAqBpG,CAAC"}
|
|
@@ -0,0 +1,205 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
/**
|
|
3
|
+
* Generated ISO20022 Type Definitions
|
|
4
|
+
* This file is auto-generated from oids.json.
|
|
5
|
+
*/
|
|
6
|
+
import * as ASN1 from '../../lib/utils/asn1.js';
|
|
7
|
+
export const OrganizationIdentificationSchema = {
|
|
8
|
+
sequenceOf: {
|
|
9
|
+
choice: [
|
|
10
|
+
{ type: 'context', kind: 'explicit', value: 0, contains: { type: 'string', kind: 'utf8' } },
|
|
11
|
+
{ type: 'context', kind: 'explicit', value: 1, contains: { type: 'string', kind: 'utf8' } },
|
|
12
|
+
{ type: 'context', kind: 'explicit', value: 2, contains: { type: 'string', kind: 'utf8' } }
|
|
13
|
+
]
|
|
14
|
+
}
|
|
15
|
+
};
|
|
16
|
+
export const OrganizationIdentificationFields = [
|
|
17
|
+
'bic',
|
|
18
|
+
'lei',
|
|
19
|
+
'other'
|
|
20
|
+
];
|
|
21
|
+
export const PersonIdentificationSchema = {
|
|
22
|
+
sequenceOf: {
|
|
23
|
+
choice: [
|
|
24
|
+
{ type: 'context', kind: 'explicit', value: 0, contains: { type: 'string', kind: 'utf8' } },
|
|
25
|
+
{ type: 'context', kind: 'explicit', value: 1, contains: { type: 'string', kind: 'utf8' } }
|
|
26
|
+
]
|
|
27
|
+
}
|
|
28
|
+
};
|
|
29
|
+
export const PersonIdentificationFields = [
|
|
30
|
+
'dateAndPlaceOfBirth',
|
|
31
|
+
'other'
|
|
32
|
+
];
|
|
33
|
+
// Generated ASN.1 schemas for ISO 20022 choice types
|
|
34
|
+
/** ASN.1 schema for AddressType */
|
|
35
|
+
export const AddressTypeSchema = { type: 'string', kind: 'utf8' };
|
|
36
|
+
/** ASN.1 schema for OrganizationIdentificationSchemeNameChoice */
|
|
37
|
+
export const OrganizationIdentificationSchemeNameChoiceSchema = { type: 'string', kind: 'utf8' };
|
|
38
|
+
/** ASN.1 schema for PersonIdentificationSchemeNameChoice */
|
|
39
|
+
export const PersonIdentificationSchemeNameChoiceSchema = { type: 'string', kind: 'utf8' };
|
|
40
|
+
// Generated ASN.1 schemas for ISO 20022 sequence types
|
|
41
|
+
/** ASN.1 schema for GenericOrganizationIdentification */
|
|
42
|
+
export const GenericOrganizationIdentificationSchema = [
|
|
43
|
+
{ type: 'context', kind: 'explicit', value: 0, contains: { type: 'string', kind: 'utf8' } },
|
|
44
|
+
{ optional: { type: 'context', kind: 'explicit', value: 1, contains: { type: 'string', kind: 'utf8' } } },
|
|
45
|
+
{ optional: { type: 'context', kind: 'explicit', value: 2, contains: OrganizationIdentificationSchemeNameChoiceSchema } }
|
|
46
|
+
];
|
|
47
|
+
/** ASN.1 schema for GenericPersonIdentification */
|
|
48
|
+
export const GenericPersonIdentificationSchema = [
|
|
49
|
+
{ type: 'context', kind: 'explicit', value: 0, contains: { type: 'string', kind: 'utf8' } },
|
|
50
|
+
{ optional: { type: 'context', kind: 'explicit', value: 1, contains: { type: 'string', kind: 'utf8' } } },
|
|
51
|
+
{ optional: { type: 'context', kind: 'explicit', value: 2, contains: PersonIdentificationSchemeNameChoiceSchema } }
|
|
52
|
+
];
|
|
53
|
+
/** ASN.1 schema for OtherContact */
|
|
54
|
+
export const OtherContactSchema = [
|
|
55
|
+
{ type: 'context', kind: 'explicit', value: 0, contains: { type: 'string', kind: 'utf8' } },
|
|
56
|
+
{ optional: { type: 'context', kind: 'explicit', value: 1, contains: { type: 'string', kind: 'utf8' } } }
|
|
57
|
+
];
|
|
58
|
+
// Generated ASN.1 schemas for choice-type sensitive attributes
|
|
59
|
+
/** ASN.1 schema for EntityType */
|
|
60
|
+
export const EntityTypeSchema = {
|
|
61
|
+
choice: [
|
|
62
|
+
OrganizationIdentificationSchema,
|
|
63
|
+
PersonIdentificationSchema
|
|
64
|
+
]
|
|
65
|
+
};
|
|
66
|
+
export const AddressFields = ['addressLines', 'addressType', 'buildingNumber', 'country', 'countrySubDivision', 'department', 'postalCode', 'streetName', 'subDepartment', 'townName'];
|
|
67
|
+
export const AddressSchema = [
|
|
68
|
+
{ optional: { type: 'context', kind: 'explicit', value: 0, contains: { type: 'string', kind: 'utf8' } } },
|
|
69
|
+
{ optional: { type: 'context', kind: 'explicit', value: 1, contains: AddressTypeSchema } },
|
|
70
|
+
{ optional: { type: 'context', kind: 'explicit', value: 2, contains: { type: 'string', kind: 'utf8' } } },
|
|
71
|
+
{ optional: { type: 'context', kind: 'explicit', value: 3, contains: { type: 'string', kind: 'utf8' } } },
|
|
72
|
+
{ optional: { type: 'context', kind: 'explicit', value: 4, contains: { type: 'string', kind: 'utf8' } } },
|
|
73
|
+
{ optional: { type: 'context', kind: 'explicit', value: 5, contains: { type: 'string', kind: 'utf8' } } },
|
|
74
|
+
{ optional: { type: 'context', kind: 'explicit', value: 6, contains: { type: 'string', kind: 'utf8' } } },
|
|
75
|
+
{ optional: { type: 'context', kind: 'explicit', value: 7, contains: { type: 'string', kind: 'utf8' } } },
|
|
76
|
+
{ optional: { type: 'context', kind: 'explicit', value: 8, contains: { type: 'string', kind: 'utf8' } } },
|
|
77
|
+
{ optional: { type: 'context', kind: 'explicit', value: 9, contains: { type: 'string', kind: 'utf8' } } }
|
|
78
|
+
];
|
|
79
|
+
export const DateAndPlaceOfBirthFields = ['birthDate', 'cityOfBirth', 'countryOfBirth', 'provinceOfBirth'];
|
|
80
|
+
export const DateAndPlaceOfBirthSchema = [
|
|
81
|
+
{ type: 'context', kind: 'explicit', value: 0, contains: ASN1.ValidateASN1.IsDate },
|
|
82
|
+
{ type: 'context', kind: 'explicit', value: 1, contains: { type: 'string', kind: 'utf8' } },
|
|
83
|
+
{ type: 'context', kind: 'explicit', value: 2, contains: { type: 'string', kind: 'utf8' } },
|
|
84
|
+
{ optional: { type: 'context', kind: 'explicit', value: 3, contains: { type: 'string', kind: 'utf8' } } }
|
|
85
|
+
];
|
|
86
|
+
export const ContactDetailsFields = ['department', 'emailAddress', 'emailPurpose', 'faxNumber', 'fullName', 'jobResponsibility', 'jobTitle', 'mobileNumber', 'namePrefix', 'other', 'phoneNumber', 'preferredMethod'];
|
|
87
|
+
export const ContactDetailsSchema = [
|
|
88
|
+
{ optional: { type: 'context', kind: 'explicit', value: 0, contains: { type: 'string', kind: 'utf8' } } },
|
|
89
|
+
{ optional: { type: 'context', kind: 'explicit', value: 1, contains: { type: 'string', kind: 'utf8' } } },
|
|
90
|
+
{ optional: { type: 'context', kind: 'explicit', value: 2, contains: { type: 'string', kind: 'utf8' } } },
|
|
91
|
+
{ optional: { type: 'context', kind: 'explicit', value: 3, contains: { type: 'string', kind: 'utf8' } } },
|
|
92
|
+
{ optional: { type: 'context', kind: 'explicit', value: 4, contains: { type: 'string', kind: 'utf8' } } },
|
|
93
|
+
{ optional: { type: 'context', kind: 'explicit', value: 5, contains: { type: 'string', kind: 'utf8' } } },
|
|
94
|
+
{ optional: { type: 'context', kind: 'explicit', value: 6, contains: { type: 'string', kind: 'utf8' } } },
|
|
95
|
+
{ optional: { type: 'context', kind: 'explicit', value: 7, contains: { type: 'string', kind: 'utf8' } } },
|
|
96
|
+
{ optional: { type: 'context', kind: 'explicit', value: 8, contains: { type: 'string', kind: 'utf8' } } },
|
|
97
|
+
{ optional: { type: 'context', kind: 'explicit', value: 9, contains: OtherContactSchema } },
|
|
98
|
+
{ optional: { type: 'context', kind: 'explicit', value: 10, contains: { type: 'string', kind: 'utf8' } } },
|
|
99
|
+
{ optional: { type: 'context', kind: 'explicit', value: 11, contains: { type: 'string', kind: 'utf8' } } }
|
|
100
|
+
];
|
|
101
|
+
export const DocumentFields = ['type', 'number', 'issuer', 'issueDate', 'expiryDate', 'issuingCountry', 'attachmentUrl'];
|
|
102
|
+
export const DocumentSchema = [
|
|
103
|
+
{ type: 'context', kind: 'explicit', value: 0, contains: { type: 'string', kind: 'utf8' } },
|
|
104
|
+
{ optional: { type: 'context', kind: 'explicit', value: 1, contains: { type: 'string', kind: 'utf8' } } },
|
|
105
|
+
{ optional: { type: 'context', kind: 'explicit', value: 2, contains: { type: 'string', kind: 'utf8' } } },
|
|
106
|
+
{ optional: { type: 'context', kind: 'explicit', value: 3, contains: ASN1.ValidateASN1.IsDate } },
|
|
107
|
+
{ optional: { type: 'context', kind: 'explicit', value: 4, contains: ASN1.ValidateASN1.IsDate } },
|
|
108
|
+
{ optional: { type: 'context', kind: 'explicit', value: 5, contains: { type: 'string', kind: 'utf8' } } },
|
|
109
|
+
{ optional: { type: 'context', kind: 'explicit', value: 6, contains: { type: 'string', kind: 'utf8' } } }
|
|
110
|
+
];
|
|
111
|
+
export const CertificateAttributeOIDDB = {
|
|
112
|
+
'fullName': '1.3.6.1.4.1.62675.1.0',
|
|
113
|
+
'firstName': '1.3.6.1.4.1.62675.1.0.1',
|
|
114
|
+
'lastName': '1.3.6.1.4.1.62675.1.0.2',
|
|
115
|
+
'middleName': '1.3.6.1.4.1.62675.1.0.3',
|
|
116
|
+
'dateOfBirth': '1.3.6.1.4.1.62675.1.1',
|
|
117
|
+
'address': '1.3.6.1.4.1.62675.1.2',
|
|
118
|
+
'email': '1.3.6.1.4.1.62675.1.3',
|
|
119
|
+
'phoneNumber': '1.3.6.1.4.1.62675.1.4',
|
|
120
|
+
'dateAndPlaceOfBirth': '1.3.6.1.4.1.62675.1.5',
|
|
121
|
+
'jobTitle': '1.3.6.1.4.1.62675.1.6',
|
|
122
|
+
'jobResponsibility': '1.3.6.1.4.1.62675.1.6.1',
|
|
123
|
+
'id': '1.3.6.1.4.1.62675.1.7',
|
|
124
|
+
'issuer': '1.3.6.1.4.1.62675.1.7.1',
|
|
125
|
+
'entityType': '1.3.6.1.4.1.62675.1.8',
|
|
126
|
+
'contactDetails': '1.3.6.1.4.1.62675.1.9',
|
|
127
|
+
'nationality': '1.3.6.1.4.1.62675.1.10',
|
|
128
|
+
'document': '1.3.6.1.4.1.62675.1.11',
|
|
129
|
+
'documentDriversLicenseFront': '1.3.6.1.4.1.62675.1.11.0',
|
|
130
|
+
'documentDriversLicenseBack': '1.3.6.1.4.1.62675.1.11.1',
|
|
131
|
+
'documentPassport': '1.3.6.1.4.1.62675.1.11.2'
|
|
132
|
+
};
|
|
133
|
+
export const SENSITIVE_CERTIFICATE_ATTRIBUTES = [
|
|
134
|
+
'fullName',
|
|
135
|
+
'firstName',
|
|
136
|
+
'lastName',
|
|
137
|
+
'middleName',
|
|
138
|
+
'dateOfBirth',
|
|
139
|
+
'address',
|
|
140
|
+
'email',
|
|
141
|
+
'phoneNumber',
|
|
142
|
+
'dateAndPlaceOfBirth',
|
|
143
|
+
'jobTitle',
|
|
144
|
+
'jobResponsibility',
|
|
145
|
+
'id',
|
|
146
|
+
'issuer',
|
|
147
|
+
'entityType',
|
|
148
|
+
'contactDetails',
|
|
149
|
+
'nationality',
|
|
150
|
+
'document',
|
|
151
|
+
'documentDriversLicenseFront',
|
|
152
|
+
'documentDriversLicenseBack',
|
|
153
|
+
'documentPassport'
|
|
154
|
+
];
|
|
155
|
+
export const SensitiveCertificateAttributeNames = [
|
|
156
|
+
'FullName',
|
|
157
|
+
'FirstName',
|
|
158
|
+
'LastName',
|
|
159
|
+
'MiddleName',
|
|
160
|
+
'DateOfBirth',
|
|
161
|
+
'Address',
|
|
162
|
+
'Email',
|
|
163
|
+
'PhoneNumber',
|
|
164
|
+
'DateAndPlaceOfBirth',
|
|
165
|
+
'JobTitle',
|
|
166
|
+
'JobResponsibility',
|
|
167
|
+
'Id',
|
|
168
|
+
'Issuer',
|
|
169
|
+
'EntityType',
|
|
170
|
+
'ContactDetails',
|
|
171
|
+
'Nationality',
|
|
172
|
+
'Document',
|
|
173
|
+
'DocumentDriversLicenseFront',
|
|
174
|
+
'DocumentDriversLicenseBack',
|
|
175
|
+
'DocumentPassport'
|
|
176
|
+
];
|
|
177
|
+
export const CertificateAttributeFieldNames = {
|
|
178
|
+
'address': AddressFields,
|
|
179
|
+
'dateAndPlaceOfBirth': DateAndPlaceOfBirthFields,
|
|
180
|
+
'contactDetails': ContactDetailsFields,
|
|
181
|
+
'document': DocumentFields
|
|
182
|
+
};
|
|
183
|
+
export const CertificateAttributeSchema = {
|
|
184
|
+
'fullName': { type: 'string', kind: 'utf8' },
|
|
185
|
+
'firstName': { type: 'string', kind: 'utf8' },
|
|
186
|
+
'lastName': { type: 'string', kind: 'utf8' },
|
|
187
|
+
'middleName': { type: 'string', kind: 'utf8' },
|
|
188
|
+
'dateOfBirth': ASN1.ValidateASN1.IsDate,
|
|
189
|
+
'address': AddressSchema,
|
|
190
|
+
'email': { type: 'string', kind: 'utf8' },
|
|
191
|
+
'phoneNumber': { type: 'string', kind: 'utf8' },
|
|
192
|
+
'dateAndPlaceOfBirth': DateAndPlaceOfBirthSchema,
|
|
193
|
+
'jobTitle': { type: 'string', kind: 'utf8' },
|
|
194
|
+
'jobResponsibility': { type: 'string', kind: 'utf8' },
|
|
195
|
+
'id': { type: 'string', kind: 'utf8' },
|
|
196
|
+
'issuer': { type: 'string', kind: 'utf8' },
|
|
197
|
+
'entityType': EntityTypeSchema,
|
|
198
|
+
'contactDetails': ContactDetailsSchema,
|
|
199
|
+
'nationality': { type: 'string', kind: 'utf8' },
|
|
200
|
+
'document': DocumentSchema,
|
|
201
|
+
'documentDriversLicenseFront': { type: 'string', kind: 'utf8' },
|
|
202
|
+
'documentDriversLicenseBack': { type: 'string', kind: 'utf8' },
|
|
203
|
+
'documentPassport': { type: 'string', kind: 'utf8' }
|
|
204
|
+
};
|
|
205
|
+
//# sourceMappingURL=iso20022.generated.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"iso20022.generated.js","sourceRoot":"","sources":["../../../src/services/kyc/iso20022.generated.ts"],"names":[],"mappings":"AAAA,oBAAoB;AACpB;;;GAGG;AAEH,OAAO,KAAK,IAAI,MAAM,yBAAyB,CAAC;AAkGhD,MAAM,CAAC,MAAM,gCAAgC,GAAgB;IAC5D,UAAU,EAAE;QACX,MAAM,EAAE;YACP,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,CAAC,EAAE,QAAQ,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,EAAE,EAAC;YAC1F,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,CAAC,EAAE,QAAQ,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,MAA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AQ,EAAE,IAAI,EAAE,MAAM,EAAE;IAC9C,aAAa,EAAE,IAAI,CAAC,YAAY,CAAC,MAAM;IACvC,SAAS,EAAE,aAAa;IACxB,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,EAAE;IACzC,aAAa,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,EAAE;IAC/C,qBAAqB,EAAE,yBAAyB;IAChD,UAAU,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,EAAE;IAC5C,mBAAmB,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,EAAE;IACrD,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,EAAE;IACtC,QAAQ,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,EAAE;IAC1C,YAAY,EAAE,gBAAgB;IAC9B,gBAAgB,EAAE,oBAAoB;IACtC,aAAa,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,EAAE;IAC/C,UAAU,EAAE,cAAc;IAC1B,6BAA6B,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,EAAE;IAC/D,4BAA4B,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,EAAE;IAC9D,kBAAkB,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,EAAE;CAC3C,CAAC","sourcesContent":["/* eslint-disable */\n/**\n * Generated ISO20022 Type Definitions\n * This file is auto-generated from oids.json.\n */\n\nimport * as ASN1 from '../../lib/utils/asn1.js';\n\n// ISO20022 Primitive Types\n/** Country code or name */\n/** OID: 1.3.6.1.4.1.62675.1.2.0 */\nexport type Country = string;\n\n/** Country subdivision (state/province) */\n/** OID: 1.3.6.1.4.1.62675.1.2.1 */\nexport type CountrySubDivision = string;\n\n/** Postal code */\n/** OID: 1.3.6.1.4.1.62675.1.2.3 */\nexport type PostalCode = string;\n\n/** Town or city name */\n/** OID: 1.3.6.1.4.1.62675.1.2.4 */\nexport type TownName = string;\n\n/** Building number */\n/** OID: 1.3.6.1.4.1.62675.1.2.5 */\nexport type BuildingNumber = string;\n\n/** Street name */\n/** OID: 1.3.6.1.4.1.62675.1.2.6 */\nexport type StreetName = string;\n\n/** Free-form address lines */\n/** OID: 1.3.6.1.4.1.62675.1.2.7 */\nexport type AddressLines = string[];\n\n/** Sub-department */\n/** OID: 1.3.6.1.4.1.62675.1.2.8 */\nexport type SubDepartment = string;\n\n/** Department */\n/** OID: 1.3.6.1.4.1.62675.1.2.9 */\nexport type Department = string;\n\n/** Purpose of email address */\n/** OID: 1.3.6.1.4.1.62675.1.3.0 */\nexport type EmailAddressPurpose = string;\n\n// ISO20022 Enumeration Types\n/** Name prefix code */\n/** OID: 1.3.6.1.4.1.62675.1.0.0 */\nexport type NamePrefixCode = 'DOCT' | 'MIST' | 'MISS' | 'MIKS' | 'MME';\n\n/** Preferred contact method */\n/** OID: 1.3.6.1.4.1.62675.1.9.0 */\nexport type PreferredContactMethodCode = 'LETT' | 'MAIL' | 'PHON' | 'FAXX' | 'CELL';\n\n// ISO20022 Choice Types\n/** Address type classification */\n/** OID: 1.3.6.1.4.1.62675.1.2.10 */\nexport type AddressType = string;\n\n/** Organization identification scheme name */\n/** OID: 1.3.6.1.4.1.62675.1.8.0.2 */\nexport type OrganizationIdentificationSchemeNameChoice = string;\n\n/** Person identification scheme name */\n/** OID: 1.3.6.1.4.1.62675.1.8.1.1 */\nexport type PersonIdentificationSchemeNameChoice = string;\n\n// ISO20022 Sequence Types\n/** Generic organization identification */\n/** OID: 1.3.6.1.4.1.62675.1.8.0.1 */\nexport interface GenericOrganizationIdentification {\n\tid: Id;\n\tschemeName?: OrganizationIdentificationSchemeNameChoice;\n\tissuer?: Issuer;\n}\n\nexport interface OrganizationIdentificationBicChoice {\n\ttag: 0;\n\tname: 'bic';\n\tvalue: string;\n}\n\nexport interface OrganizationIdentificationLeiChoice {\n\ttag: 1;\n\tname: 'lei';\n\tvalue: string;\n}\n\nexport interface OrganizationIdentificationOtherChoice {\n\ttag: 2;\n\tname: 'other';\n\tvalue: GenericOrganizationIdentification[];\n}\nexport type OrganizationIdentificationChoice =\n\t| OrganizationIdentificationBicChoice\n\t| OrganizationIdentificationLeiChoice\n\t| OrganizationIdentificationOtherChoice;\n\nexport type OrganizationIdentification = OrganizationIdentificationChoice[];\n\nexport const OrganizationIdentificationSchema: ASN1.Schema = {\n\tsequenceOf: {\n\t\tchoice: [\n\t\t\t{ type: 'context', kind: 'explicit', value: 0, contains: { type: 'string', kind: 'utf8' }},\n\t\t\t{ type: 'context', kind: 'explicit', value: 1, contains: { type: 'string', kind: 'utf8' }},\n\t\t\t{ type: 'context', kind: 'explicit', value: 2, contains: { type: 'string', kind: 'utf8' }}\n\t\t]\n\t}\n} as const satisfies ASN1.Schema;\n\nexport const OrganizationIdentificationFields = [\n\t'bic',\n\t'lei',\n\t'other'\n] as const;\n\n\n/** Generic person identification */\n/** OID: 1.3.6.1.4.1.62675.1.8.1.0 */\nexport interface GenericPersonIdentification {\n\tid: Id;\n\tschemeName?: PersonIdentificationSchemeNameChoice;\n\tissuer?: Issuer;\n}\n\nexport interface PersonIdentificationDateAndPlaceOfBirthChoice {\n\ttag: 0;\n\tname: 'dateAndPlaceOfBirth';\n\tvalue: DateAndPlaceOfBirth;\n}\n\nexport interface PersonIdentificationOtherChoice {\n\ttag: 1;\n\tname: 'other';\n\tvalue: GenericPersonIdentification[];\n}\nexport type PersonIdentificationChoice =\n\t| PersonIdentificationDateAndPlaceOfBirthChoice\n\t| PersonIdentificationOtherChoice;\n\nexport type PersonIdentification = PersonIdentificationChoice[];\n\nexport const PersonIdentificationSchema: ASN1.Schema = {\n\tsequenceOf: {\n\t\tchoice: [\n\t\t\t{ type: 'context', kind: 'explicit', value: 0, contains: { type: 'string', kind: 'utf8' }},\n\t\t\t{ type: 'context', kind: 'explicit', value: 1, contains: { type: 'string', kind: 'utf8' }}\n\t\t]\n\t}\n} as const satisfies ASN1.Schema;\n\nexport const PersonIdentificationFields = [\n\t'dateAndPlaceOfBirth',\n\t'other'\n] as const;\n\n\n/** Other contact method */\n/** OID: 1.3.6.1.4.1.62675.1.9.1 */\nexport interface OtherContact {\n\tid?: Id;\n\tchannelType: string;\n}\n\n\n// Generated ASN.1 schemas for ISO 20022 choice types\n/** ASN.1 schema for AddressType */\nexport const AddressTypeSchema: ASN1.Schema = { type: 'string', kind: 'utf8' };\n\n/** ASN.1 schema for OrganizationIdentificationSchemeNameChoice */\nexport const OrganizationIdentificationSchemeNameChoiceSchema: ASN1.Schema = { type: 'string', kind: 'utf8' };\n\n/** ASN.1 schema for PersonIdentificationSchemeNameChoice */\nexport const PersonIdentificationSchemeNameChoiceSchema: ASN1.Schema = { type: 'string', kind: 'utf8' };\n\n// Generated ASN.1 schemas for ISO 20022 sequence types\n/** ASN.1 schema for GenericOrganizationIdentification */\nexport const GenericOrganizationIdentificationSchema: ASN1.Schema = [\n\t{ type: 'context', kind: 'explicit', value: 0, contains: { type: 'string', kind: 'utf8' }},\n\t{ optional: { type: 'context', kind: 'explicit', value: 1, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 2, contains: OrganizationIdentificationSchemeNameChoiceSchema }}\n] as const satisfies ASN1.Schema;\n\n/** ASN.1 schema for GenericPersonIdentification */\nexport const GenericPersonIdentificationSchema: ASN1.Schema = [\n\t{ type: 'context', kind: 'explicit', value: 0, contains: { type: 'string', kind: 'utf8' }},\n\t{ optional: { type: 'context', kind: 'explicit', value: 1, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 2, contains: PersonIdentificationSchemeNameChoiceSchema }}\n] as const satisfies ASN1.Schema;\n\n/** ASN.1 schema for OtherContact */\nexport const OtherContactSchema: ASN1.Schema = [\n\t{ type: 'context', kind: 'explicit', value: 0, contains: { type: 'string', kind: 'utf8' }},\n\t{ optional: { type: 'context', kind: 'explicit', value: 1, contains: { type: 'string', kind: 'utf8' }}}\n] as const satisfies ASN1.Schema;\n\n// Generated ASN.1 schemas for choice-type sensitive attributes\n/** ASN.1 schema for EntityType */\nexport const EntityTypeSchema: ASN1.Schema = {\n\tchoice: [\n\t\tOrganizationIdentificationSchema,\n\t\tPersonIdentificationSchema\n\t]\n} as const satisfies ASN1.Schema;\n\n/** Person's full name */\n/** OID: 1.3.6.1.4.1.62675.1.0 */\nexport type FullName = string;\n\n/** Person's first name */\n/** OID: 1.3.6.1.4.1.62675.1.0.1 */\nexport type FirstName = string;\n\n/** Person's last name */\n/** OID: 1.3.6.1.4.1.62675.1.0.2 */\nexport type LastName = string;\n\n/** Person's middle name */\n/** OID: 1.3.6.1.4.1.62675.1.0.3 */\nexport type MiddleName = string;\n\n/** Date of birth */\n/** OID: 1.3.6.1.4.1.62675.1.1 */\nexport type DateOfBirth = Date;\n\n/** Physical address */\n/** OID: 1.3.6.1.4.1.62675.1.2 */\nexport interface Address {\n\taddressType?: AddressType;\n\tdepartment?: Department;\n\tsubDepartment?: SubDepartment;\n\tstreetName?: StreetName;\n\tbuildingNumber?: BuildingNumber;\n\tpostalCode?: PostalCode;\n\ttownName?: TownName;\n\tcountrySubDivision?: CountrySubDivision;\n\tcountry?: Country;\n\taddressLines?: AddressLines;\n}\n\n/** Email address */\n/** OID: 1.3.6.1.4.1.62675.1.3 */\nexport type Email = string;\n\n/** Phone number */\n/** OID: 1.3.6.1.4.1.62675.1.4 */\nexport type PhoneNumber = string;\n\n/** Date and place of birth information */\n/** OID: 1.3.6.1.4.1.62675.1.5 */\nexport interface DateAndPlaceOfBirth {\n\tbirthDate: BirthDate;\n\tprovinceOfBirth?: CountrySubDivision;\n\tcityOfBirth: TownName;\n\tcountryOfBirth: Country;\n}\n\n/** Job title */\n/** OID: 1.3.6.1.4.1.62675.1.6 */\nexport type JobTitle = string;\n\n/** Job responsibility */\n/** OID: 1.3.6.1.4.1.62675.1.6.1 */\nexport type JobResponsibility = string;\n\n/** Identifier */\n/** OID: 1.3.6.1.4.1.62675.1.7 */\nexport type Id = string;\n\n/** Issuer identifier */\n/** OID: 1.3.6.1.4.1.62675.1.7.1 */\nexport type Issuer = string;\n\n/** Entity type (organization or person) */\n/** OID: 1.3.6.1.4.1.62675.1.8 */\nexport type EntityType = OrganizationIdentification | PersonIdentification;\n\n/** Contact details */\n/** OID: 1.3.6.1.4.1.62675.1.9 */\nexport interface ContactDetails {\n\tnamePrefix?: NamePrefixCode;\n\tfullName?: FullName;\n\tphoneNumber?: PhoneNumber;\n\tmobileNumber?: PhoneNumber;\n\tfaxNumber?: PhoneNumber;\n\temailAddress?: EmailAddress;\n\temailPurpose?: EmailAddressPurpose;\n\tjobTitle?: JobTitle;\n\tjobResponsibility?: JobResponsibility;\n\tdepartment?: Department;\n\tother?: OtherContact[];\n\tpreferredMethod?: PreferredContactMethodCode;\n}\n\n/** Nationality */\n/** OID: 1.3.6.1.4.1.62675.1.10 */\nexport type Nationality = string;\n\n/** Document information */\n/** OID: 1.3.6.1.4.1.62675.1.11 */\nexport interface Document {\n\ttype: string;\n\tnumber?: string;\n\tissuer?: Issuer;\n\tissueDate?: Date;\n\texpiryDate?: Date;\n\tissuingCountry?: Country;\n\tattachmentUrl?: string;\n}\n\n/** Driver's license front side document */\n/** OID: 1.3.6.1.4.1.62675.1.11.0 */\nexport type DocumentDriversLicenseFront = Document;\n\n/** Driver's license back side document */\n/** OID: 1.3.6.1.4.1.62675.1.11.1 */\nexport type DocumentDriversLicenseBack = Document;\n\n/** Passport document */\n/** OID: 1.3.6.1.4.1.62675.1.11.2 */\nexport type DocumentPassport = Document;\n\n// Token aliases for sensitive attributes\n/** Alias for DateOfBirth */\nexport type BirthDate = DateOfBirth;\n\n/** Alias for Email */\nexport type EmailAddress = Email;\n\n/** Union type of all sensitive attribute types */\nexport type SensitiveAttributeType =\n\t| FullName\n\t| FirstName\n\t| LastName\n\t| MiddleName\n\t| DateOfBirth\n\t| Address\n\t| Email\n\t| PhoneNumber\n\t| DateAndPlaceOfBirth\n\t| JobTitle\n\t| JobResponsibility\n\t| Id\n\t| Issuer\n\t| EntityType\n\t| ContactDetails\n\t| Nationality\n\t| Document\n\t| DocumentDriversLicenseFront\n\t| DocumentDriversLicenseBack\n\t| DocumentPassport;\n\n/** Map of attribute name to acceptable input type for CertificateBuilder.setAttribute */\nexport interface CertificateAttributeValueMap {\n\t'fullName': FullName;\n\t'firstName': FirstName;\n\t'lastName': LastName;\n\t'middleName': MiddleName;\n\t'dateOfBirth': DateOfBirth;\n\t'address': Address;\n\t'email': Email;\n\t'phoneNumber': PhoneNumber;\n\t'dateAndPlaceOfBirth': DateAndPlaceOfBirth;\n\t'jobTitle': JobTitle;\n\t'jobResponsibility': JobResponsibility;\n\t'id': Id;\n\t'issuer': Issuer;\n\t'entityType': EntityType;\n\t'contactDetails': ContactDetails;\n\t'nationality': Nationality;\n\t'document': Document;\n\t'documentDriversLicenseFront': DocumentDriversLicenseFront;\n\t'documentDriversLicenseBack': DocumentDriversLicenseBack;\n\t'documentPassport': DocumentPassport;\n}\n\n/** Helper generic to get attribute value type by name */\nexport type CertificateAttributeValue<Name extends keyof CertificateAttributeValueMap> = CertificateAttributeValueMap[Name];\n\nexport const AddressFields = ['addressLines', 'addressType', 'buildingNumber', 'country', 'countrySubDivision', 'department', 'postalCode', 'streetName', 'subDepartment', 'townName'] as const;\nexport const AddressSchema: ASN1.Schema = [\n\t{ optional: { type: 'context', kind: 'explicit', value: 0, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 1, contains: AddressTypeSchema }},\n\t{ optional: { type: 'context', kind: 'explicit', value: 2, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 3, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 4, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 5, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 6, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 7, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 8, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 9, contains: { type: 'string', kind: 'utf8' }}}\n] as const satisfies ASN1.Schema;\nexport const DateAndPlaceOfBirthFields = ['birthDate', 'cityOfBirth', 'countryOfBirth', 'provinceOfBirth'] as const;\nexport const DateAndPlaceOfBirthSchema: ASN1.Schema = [\n\t{ type: 'context', kind: 'explicit', value: 0, contains: ASN1.ValidateASN1.IsDate },\n\t{ type: 'context', kind: 'explicit', value: 1, contains: { type: 'string', kind: 'utf8' }},\n\t{ type: 'context', kind: 'explicit', value: 2, contains: { type: 'string', kind: 'utf8' }},\n\t{ optional: { type: 'context', kind: 'explicit', value: 3, contains: { type: 'string', kind: 'utf8' }}}\n] as const satisfies ASN1.Schema;\nexport const ContactDetailsFields = ['department', 'emailAddress', 'emailPurpose', 'faxNumber', 'fullName', 'jobResponsibility', 'jobTitle', 'mobileNumber', 'namePrefix', 'other', 'phoneNumber', 'preferredMethod'] as const;\nexport const ContactDetailsSchema: ASN1.Schema = [\n\t{ optional: { type: 'context', kind: 'explicit', value: 0, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 1, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 2, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 3, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 4, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 5, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 6, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 7, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 8, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 9, contains: OtherContactSchema }},\n\t{ optional: { type: 'context', kind: 'explicit', value: 10, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 11, contains: { type: 'string', kind: 'utf8' }}}\n] as const satisfies ASN1.Schema;\nexport const DocumentFields = ['type', 'number', 'issuer', 'issueDate', 'expiryDate', 'issuingCountry', 'attachmentUrl'] as const;\nexport const DocumentSchema: ASN1.Schema = [\n\t{ type: 'context', kind: 'explicit', value: 0, contains: { type: 'string', kind: 'utf8' }},\n\t{ optional: { type: 'context', kind: 'explicit', value: 1, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 2, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 3, contains: ASN1.ValidateASN1.IsDate }},\n\t{ optional: { type: 'context', kind: 'explicit', value: 4, contains: ASN1.ValidateASN1.IsDate }},\n\t{ optional: { type: 'context', kind: 'explicit', value: 5, contains: { type: 'string', kind: 'utf8' }}},\n\t{ optional: { type: 'context', kind: 'explicit', value: 6, contains: { type: 'string', kind: 'utf8' }}}\n] as const satisfies ASN1.Schema;\nexport const CertificateAttributeOIDDB = {\n\t'fullName': '1.3.6.1.4.1.62675.1.0',\n\t'firstName': '1.3.6.1.4.1.62675.1.0.1',\n\t'lastName': '1.3.6.1.4.1.62675.1.0.2',\n\t'middleName': '1.3.6.1.4.1.62675.1.0.3',\n\t'dateOfBirth': '1.3.6.1.4.1.62675.1.1',\n\t'address': '1.3.6.1.4.1.62675.1.2',\n\t'email': '1.3.6.1.4.1.62675.1.3',\n\t'phoneNumber': '1.3.6.1.4.1.62675.1.4',\n\t'dateAndPlaceOfBirth': '1.3.6.1.4.1.62675.1.5',\n\t'jobTitle': '1.3.6.1.4.1.62675.1.6',\n\t'jobResponsibility': '1.3.6.1.4.1.62675.1.6.1',\n\t'id': '1.3.6.1.4.1.62675.1.7',\n\t'issuer': '1.3.6.1.4.1.62675.1.7.1',\n\t'entityType': '1.3.6.1.4.1.62675.1.8',\n\t'contactDetails': '1.3.6.1.4.1.62675.1.9',\n\t'nationality': '1.3.6.1.4.1.62675.1.10',\n\t'document': '1.3.6.1.4.1.62675.1.11',\n\t'documentDriversLicenseFront': '1.3.6.1.4.1.62675.1.11.0',\n\t'documentDriversLicenseBack': '1.3.6.1.4.1.62675.1.11.1',\n\t'documentPassport': '1.3.6.1.4.1.62675.1.11.2'\n} as const;\n\nexport const SENSITIVE_CERTIFICATE_ATTRIBUTES = [\n\t'fullName',\n\t'firstName',\n\t'lastName',\n\t'middleName',\n\t'dateOfBirth',\n\t'address',\n\t'email',\n\t'phoneNumber',\n\t'dateAndPlaceOfBirth',\n\t'jobTitle',\n\t'jobResponsibility',\n\t'id',\n\t'issuer',\n\t'entityType',\n\t'contactDetails',\n\t'nationality',\n\t'document',\n\t'documentDriversLicenseFront',\n\t'documentDriversLicenseBack',\n\t'documentPassport'\n] as const;\n\nexport type SensitiveCertificateAttributeNames = typeof SENSITIVE_CERTIFICATE_ATTRIBUTES[number];\n\nexport const SensitiveCertificateAttributeNames = [\n\t'FullName',\n\t'FirstName',\n\t'LastName',\n\t'MiddleName',\n\t'DateOfBirth',\n\t'Address',\n\t'Email',\n\t'PhoneNumber',\n\t'DateAndPlaceOfBirth',\n\t'JobTitle',\n\t'JobResponsibility',\n\t'Id',\n\t'Issuer',\n\t'EntityType',\n\t'ContactDetails',\n\t'Nationality',\n\t'Document',\n\t'DocumentDriversLicenseFront',\n\t'DocumentDriversLicenseBack',\n\t'DocumentPassport'\n] as const;\n\nexport const CertificateAttributeFieldNames: { readonly [K in keyof typeof CertificateAttributeOIDDB]?: readonly string[] } = {\n\t'address': AddressFields,\n\t'dateAndPlaceOfBirth': DateAndPlaceOfBirthFields,\n\t'contactDetails': ContactDetailsFields,\n\t'document': DocumentFields\n} as const;\n\nexport const CertificateAttributeSchema: { readonly [K in keyof typeof CertificateAttributeOIDDB]: ASN1.Schema } = {\n\t'fullName': { type: 'string', kind: 'utf8' },\n\t'firstName': { type: 'string', kind: 'utf8' },\n\t'lastName': { type: 'string', kind: 'utf8' },\n\t'middleName': { type: 'string', kind: 'utf8' },\n\t'dateOfBirth': ASN1.ValidateASN1.IsDate,\n\t'address': AddressSchema,\n\t'email': { type: 'string', kind: 'utf8' },\n\t'phoneNumber': { type: 'string', kind: 'utf8' },\n\t'dateAndPlaceOfBirth': DateAndPlaceOfBirthSchema,\n\t'jobTitle': { type: 'string', kind: 'utf8' },\n\t'jobResponsibility': { type: 'string', kind: 'utf8' },\n\t'id': { type: 'string', kind: 'utf8' },\n\t'issuer': { type: 'string', kind: 'utf8' },\n\t'entityType': EntityTypeSchema,\n\t'contactDetails': ContactDetailsSchema,\n\t'nationality': { type: 'string', kind: 'utf8' },\n\t'document': DocumentSchema,\n\t'documentDriversLicenseFront': { type: 'string', kind: 'utf8' },\n\t'documentDriversLicenseBack': { type: 'string', kind: 'utf8' },\n\t'documentPassport': { type: 'string', kind: 'utf8' }\n} as const;\n"]}
|