czech-data-box 0.1.0

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.
Files changed (41) hide show
  1. package/.gitattributes +16 -0
  2. package/.nvmrc +1 -0
  3. package/.prettierignore +1 -0
  4. package/.prettierrc.yaml +6 -0
  5. package/.vscode/launch.json +15 -0
  6. package/.vscode/settings.json +5 -0
  7. package/CHANGELOG.md +17 -0
  8. package/CODE_OF_CONDUCT.md +128 -0
  9. package/CONTRIBUTING.md +84 -0
  10. package/LICENSE +21 -0
  11. package/README.md +76 -0
  12. package/eslint.config.js +26 -0
  13. package/examples/db_login_with_certificate.js +27 -0
  14. package/examples/db_search.js +27 -0
  15. package/examples/dm_operations.js +58 -0
  16. package/package.json +57 -0
  17. package/resources/certs/cacert_postsignum_vca4.pem +44 -0
  18. package/resources/wsdl/ChangePassword.wsdl +84 -0
  19. package/resources/wsdl/ChangePasswordTypes.xsd +69 -0
  20. package/resources/wsdl/ExtWs.wsdl +65 -0
  21. package/resources/wsdl/dbTypes.xsd +1688 -0
  22. package/resources/wsdl/db_access.wsdl +197 -0
  23. package/resources/wsdl/db_manipulations.wsdl +598 -0
  24. package/resources/wsdl/db_search.wsdl +362 -0
  25. package/resources/wsdl/dmBaseTypes.xsd +1497 -0
  26. package/resources/wsdl/dm_VoDZ.wsdl +212 -0
  27. package/resources/wsdl/dm_info.wsdl +412 -0
  28. package/resources/wsdl/dm_operations.wsdl +242 -0
  29. package/src/index.js +4 -0
  30. package/src/lib/ISDSBox.js +309 -0
  31. package/src/lib/ISDSSentOutFiles.js +84 -0
  32. package/src/lib/ISDSSoapClient.js +201 -0
  33. package/src/lib/config.js +64 -0
  34. package/src/models/DataBox.js +142 -0
  35. package/src/models/DataMessage.js +153 -0
  36. package/src/models/DataMessageFile.js +69 -0
  37. package/src/models/DataMessageFiles.js +23 -0
  38. package/test/ISDSBox.test.js +129 -0
  39. package/test/ISDSSentOutFiles.test.js +124 -0
  40. package/test/ISDSSoapClient.test.js +81 -0
  41. package/test/communication_test.pdf +0 -0
@@ -0,0 +1,84 @@
1
+ <?xml version="1.0" encoding="UTF-8" ?>
2
+ <!-- *********************************************************************
3
+ WSDL pro služby související s OTP přihlašováním
4
+
5
+ verze: 2.31
6
+ klasifikace: Veřejný dokument
7
+
8
+ Seznam služeb:
9
+ ==============
10
+ ChangePasswordOTP
11
+ SendSMSCode
12
+
13
+ změny:
14
+ 15.9.2011 verze 1.0
15
+ 21.11.2017 verze 2.27 - sjednocení verzí
16
+ 5.9.2018 verze 2.31 - sjednocení verzí
17
+ ************************************************************************ -->
18
+
19
+ <definitions xmlns="http://schemas.xmlsoap.org/wsdl/"
20
+ xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
21
+ xmlns:tns="http://isds.czechpoint.cz/v20/asws"
22
+ targetNamespace="http://isds.czechpoint.cz/v20/asws">
23
+ <types>
24
+ <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://isds.czechpoint.cz/v20/asws">
25
+ <xsd:include schemaLocation="ChangePasswordTypes.xsd"/>
26
+ </xsd:schema>
27
+ </types>
28
+ <message name="SendSMSCodeRequest">
29
+ <part element="tns:SendSMSCode" name="SendSMSCode">
30
+ </part>
31
+ </message>
32
+ <message name="SendSMSCodeResponse">
33
+ <part element="tns:SendSMSCodeResponse" name="SendSMSCodeResponse">
34
+ </part>
35
+ </message>
36
+ <message name="ChangePasswordOTPRequest">
37
+ <part element="tns:ChangePasswordOTP" name="ChangePasswordOTP">
38
+ </part>
39
+ </message>
40
+ <message name="ChangePasswordOTPResponse">
41
+ <part element="tns:ChangePasswordOTPResponse" name="ChangePasswordOTPResponse">
42
+ </part>
43
+ </message>
44
+ <portType name="ChangePassword">
45
+ <operation name="SendSMSCode">
46
+ <input message="tns:SendSMSCodeRequest" name="SendSMSCodeRequest">
47
+ </input>
48
+ <output message="tns:SendSMSCodeResponse" name="SendSMSCodeResponse">
49
+ </output>
50
+ </operation>
51
+ <operation name="ChangePasswordOTP">
52
+ <input message="tns:ChangePasswordOTPRequest" name="ChangePasswordOTPRequest">
53
+ </input>
54
+ <output message="tns:ChangePasswordOTPResponse" name="ChangePasswordOTPResponse">
55
+ </output>
56
+ </operation>
57
+ </portType>
58
+ <binding name="ChangePasswordSoap11" type="tns:ChangePassword">
59
+ <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
60
+ <operation name="SendSMSCode">
61
+ <soap:operation soapAction=""/>
62
+ <input name="SendSMSCodeRequest">
63
+ <soap:body use="literal"/>
64
+ </input>
65
+ <output name="SendSMSCodeResponse">
66
+ <soap:body use="literal"/>
67
+ </output>
68
+ </operation>
69
+ <operation name="ChangePasswordOTP">
70
+ <soap:operation soapAction=""/>
71
+ <input name="ChangePasswordOTPRequest">
72
+ <soap:body use="literal"/>
73
+ </input>
74
+ <output name="ChangePasswordOTPResponse">
75
+ <soap:body use="literal"/>
76
+ </output>
77
+ </operation>
78
+ </binding>
79
+ <service name="ChangePasswordService">
80
+ <port binding="tns:ChangePasswordSoap11" name="ChangePasswordSoap11">
81
+ <soap:address location="https://www.mojedatovaschranka.cz/asws/changePassword"/>
82
+ </port>
83
+ </service>
84
+ </definitions>
@@ -0,0 +1,69 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <!-- ************************************************************************
3
+ XSD schema typů použitých v ChangePasswordOTP.wsdl
4
+
5
+ verze: 2.31
6
+ klasifikace: Veřejný dokument
7
+
8
+ změny:
9
+ 15.9.2011 verze 1.0
10
+ 21.11.2017 verze 2.27 - sjednocení verzí
11
+ 5.9.2018 verze 2.31 - sjednocení verzí
12
+ **************************************************************************** -->
13
+
14
+ <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:v1="http://isds.czechpoint.cz/v20/asws" attributeFormDefault="unqualified" elementFormDefault="qualified" targetNamespace="http://isds.czechpoint.cz/v20/asws">
15
+ <xs:element name="ChangePasswordOTP" type="v1:tChngPasswInputOTP"/>
16
+ <xs:complexType name="tChngPasswInputOTP">
17
+ <xs:sequence>
18
+ <xs:element maxOccurs="1" minOccurs="1" name="dbOldPassword" type="xs:string">
19
+ <xs:annotation>
20
+ <xs:documentation>původní heslo</xs:documentation>
21
+ </xs:annotation>
22
+ </xs:element>
23
+ <xs:element maxOccurs="1" minOccurs="1" name="dbNewPassword" type="xs:string">
24
+ <xs:annotation>
25
+ <xs:documentation>nové heslo</xs:documentation>
26
+ </xs:annotation>
27
+ </xs:element>
28
+ <xs:element maxOccurs="1" minOccurs="1" name="dbOTPType" type="v1:tAuthType">
29
+ <xs:annotation>
30
+ <xs:documentation>typ přihlášení</xs:documentation>
31
+ </xs:annotation>
32
+ </xs:element>
33
+ </xs:sequence>
34
+ </xs:complexType>
35
+ <xs:simpleType name="tAuthType">
36
+ <xs:restriction base="xs:string">
37
+ <xs:enumeration value="TOTP"/>
38
+ <xs:enumeration value="HOTP"/>
39
+ </xs:restriction>
40
+ </xs:simpleType>
41
+ <xs:element name="ChangePasswordOTPResponse" type="v1:tReqStatusOutput"/>
42
+ <xs:complexType name="tReqStatusOutput">
43
+ <xs:sequence>
44
+ <xs:element name="dbStatus" type="v1:tDbReqStatus"/>
45
+ </xs:sequence>
46
+ </xs:complexType>
47
+ <xs:complexType name="tDbReqStatus">
48
+ <xs:annotation>
49
+ <xs:documentation>návratový typ WS</xs:documentation>
50
+ </xs:annotation>
51
+ <xs:group ref="v1:gDbReqStatus"/>
52
+ </xs:complexType>
53
+ <xs:group name="gDbReqStatus">
54
+ <xs:sequence>
55
+ <xs:element name="dbStatusCode" type="xs:string"/>
56
+ <xs:element name="dbStatusMessage" type="xs:string"/>
57
+ <xs:element maxOccurs="1" minOccurs="0" name="dbStatusRefNumber" nillable="true" type="xs:string">
58
+ <xs:annotation>
59
+ <xs:documentation>nepovinné referenční číslo žádosti</xs:documentation>
60
+ </xs:annotation>
61
+ </xs:element>
62
+ </xs:sequence>
63
+ </xs:group>
64
+ <xs:element name="SendSMSCode" type="v1:tSendSMSCode"/>
65
+ <xs:complexType name="tSendSMSCode">
66
+ </xs:complexType>
67
+ <xs:element name="SendSMSCodeResponse" type="v1:tReqStatusOutput"/>
68
+
69
+ </xs:schema>
@@ -0,0 +1,65 @@
1
+ <?xml version="1.0" encoding="UTF-8" standalone="no"?><wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:sch="http://agw-as.cz/ats-ws/extWs/v1" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://agw-as.cz/ats-ws/extWs/v1" targetNamespace="http://agw-as.cz/ats-ws/extWs/v1">
2
+ <wsdl:types>
3
+ <xs:schema xmlns:v1="http://agw-as.cz/ats-ws/extWs/v1" xmlns:xs="http://www.w3.org/2001/XMLSchema" attributeFormDefault="unqualified" elementFormDefault="qualified" targetNamespace="http://agw-as.cz/ats-ws/extWs/v1">
4
+
5
+
6
+ <xs:element name="extWsLogoutRequest" type="v1:extWsLogoutRequestType"/>
7
+ <xs:element name="extWsLogoutResponse" type="v1:extWsLogoutResponseType"/>
8
+
9
+ <xs:complexType name="extWsLogoutRequestType">
10
+ <xs:sequence>
11
+ <xs:element name="timeLimitedId" type="xs:string"/>
12
+ </xs:sequence>
13
+ </xs:complexType>
14
+ <xs:complexType name="extWsLogoutResponseType">
15
+ <xs:sequence>
16
+ <xs:element name="status" type="v1:extWsLogoutResponseStatusType">
17
+ <xs:annotation>
18
+ <xs:documentation>OK/SYSTEM_ERROR</xs:documentation>
19
+ </xs:annotation>
20
+ </xs:element>
21
+ </xs:sequence>
22
+ </xs:complexType>
23
+ <xs:simpleType name="extWsLogoutResponseStatusType">
24
+ <xs:restriction base="xs:string">
25
+ <xs:enumeration value="OK"/>
26
+ <xs:enumeration value="SYSTEM_ERROR"/>
27
+ </xs:restriction>
28
+ </xs:simpleType>
29
+
30
+ </xs:schema>
31
+ </wsdl:types>
32
+ <wsdl:message name="extWsLogoutResponse">
33
+ <wsdl:part element="tns:extWsLogoutResponse" name="extWsLogoutResponse">
34
+ </wsdl:part>
35
+ </wsdl:message>
36
+ <wsdl:message name="extWsLogoutRequest">
37
+ <wsdl:part element="tns:extWsLogoutRequest" name="extWsLogoutRequest">
38
+ </wsdl:part>
39
+ </wsdl:message>
40
+ <wsdl:portType name="ExtWs">
41
+ <wsdl:operation name="extWsLogout">
42
+ <wsdl:input message="tns:extWsLogoutRequest" name="extWsLogoutRequest">
43
+ </wsdl:input>
44
+ <wsdl:output message="tns:extWsLogoutResponse" name="extWsLogoutResponse">
45
+ </wsdl:output>
46
+ </wsdl:operation>
47
+ </wsdl:portType>
48
+ <wsdl:binding name="ExtWsSoap11" type="tns:ExtWs">
49
+ <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
50
+ <wsdl:operation name="extWsLogout">
51
+ <soap:operation soapAction=""/>
52
+ <wsdl:input name="extWsLogoutRequest">
53
+ <soap:body use="literal"/>
54
+ </wsdl:input>
55
+ <wsdl:output name="extWsLogoutResponse">
56
+ <soap:body use="literal"/>
57
+ </wsdl:output>
58
+ </wsdl:operation>
59
+ </wsdl:binding>
60
+ <wsdl:service name="ExtWsService">
61
+ <wsdl:port binding="tns:ExtWsSoap11" name="ExtWsSoap11">
62
+ <soap:address location="https://cert.mojedatovaschranka.cz/asws/extWsEndpoint"/>
63
+ </wsdl:port>
64
+ </wsdl:service>
65
+ </wsdl:definitions>