C2S: TLS - Client Cert: Two-way TLS - #2939

Test duration: 1.856s

Passed Tests
tigase.tests.server.TestTwoWayTLS
testConnectionWithCertificate 0.650s
2020-07-10 15:17:59 |
2020-07-10 15:17:59 | null / [TestClass name=class tigase.tests.server.TestTwoWayTLS]
2020-07-10 15:17:59 | ------------------------------------
2020-07-10 15:17:59 | == test connection with OK certificate
2020-07-10 15:17:59 | Private key: SunRsaSign RSA private CRT key, 1024 bits
  params: null
  modulus: 152761233143497582116717054095409374921484861881219838581049774918827920370633380183327557894608259805888440781489432167999315517717065393898030606251674341936883646661541606206019244807482197161925251151354063576657073657664807420344658857040469040824225256741751244332063539034528087632994997564807553381137
  private exponent: 98495180855267006880449148387256336827780708968259540398261124082121436794199980362645365005944224275716342732542189079313656049508709817119416227440541220185215155267440596336780035042728733097642326630147794535561752716218858405844442745910716925045907430666325183330107989176483374996594251719256717909761
[
[
  Version: V3
  Subject: CN=Client, O=Internet Widgits Pty Ltd, ST=Some-State, C=US
  Signature Algorithm: SHA256withRSA, OID = 1.2.840.113549.1.1.11

  Key:  Sun RSA public key, 1024 bits
  params: null
  modulus: 152761233143497582116717054095409374921484861881219838581049774918827920370633380183327557894608259805888440781489432167999315517717065393898030606251674341936883646661541606206019244807482197161925251151354063576657073657664807420344658857040469040824225256741751244332063539034528087632994997564807553381137
  public exponent: 65537
  Validity: [From: Mon Apr 20 04:19:08 PDT 2015,
               To: Fri Sep 05 04:19:08 PDT 2042]
  Issuer: CN=ROOT, O=Internet Widgits Pty Ltd, ST=Some-State, C=US
  SerialNumber: [    96f20c6d 2893e805]

Certificate Extensions: 4
[1]: ObjectId: 2.16.840.1.113730.1.13 Criticality=false
Extension unknown: DER encoded OCTET string =
0000: 04 1F 16 1D 4F 70 65 6E   53 53 4C 20 47 65 6E 65  ....OpenSSL Gene
0010: 72 61 74 65 64 20 43 65   72 74 69 66 69 63 61 74  rated Certificat
0020: 65                                                 e


[2]: ObjectId: 2.5.29.35 Criticality=false
AuthorityKeyIdentifier [
KeyIdentifier [
0000: 62 A9 11 75 F0 62 1D B8   CA F9 F3 7E A2 65 5A AB  b..u.b.......eZ.
0010: C9 97 49 0D                                        ..I.
]
]

[3]: ObjectId: 2.5.29.19 Criticality=false
BasicConstraints:[
  CA:false
  PathLen: undefined
]

[4]: ObjectId: 2.5.29.14 Criticality=false
SubjectKeyIdentifier [
KeyIdentifier [
0000: C1 FA 2F 1F 5C 62 EC 83   B0 7B 91 A7 A7 46 BB 62  ../.\b.......F.b
0010: 5D 23 3F D0                                        ]#?.
]
]

]
  Algorithm: [SHA256withRSA]
  Signature:
0000: 61 8E 44 18 EC 3B A3 3E   DF 8A DF 64 6F 79 FD C2  a.D..;.>...doy..
0010: 66 4F AC 58 4A 75 FD 08   12 F8 B4 69 13 59 75 2A  fO.XJu.....i.Yu*
0020: FD 64 F8 35 CC 40 64 D9   E3 F4 12 C1 68 A4 04 4E  .d.5.@d.....h..N
0030: 11 CB B2 ED 81 30 AA 5E   C9 F9 C7 57 0A 1E B6 2C  .....0.^...W...,
0040: F5 28 95 E9 D7 FD 95 36   A5 10 D1 0E 85 08 55 A0  .(.....6......U.
0050: C5 61 B9 B1 56 3A 81 D8   F5 95 E8 04 AB DB EE C3  .a..V:..........
0060: 2F B3 FC 70 00 F9 4F DD   D5 92 2E 25 0C 08 C2 56  /..p..O....%...V
0070: 94 9B CA 9F BA 64 4A 1F   11 91 C4 21 C2 75 D3 01  .....dJ....!.u..
0080: E3 91 27 7C F1 7B E0 8B   F9 1C ED 06 7D 6F 02 FC  ..'..........o..
0090: C4 CD 63 98 64 20 F3 A9   18 51 F8 41 57 B0 AE C9  ..c.d ...Q.AW...
00A0: A4 C7 C3 AD 3E 2C CF 30   59 E9 22 CD A3 6A F7 49  ....>,.0Y."..j.I
00B0: BA 42 7F D7 D6 4B D0 BE   AB A5 7C 46 F0 11 C1 D7  .B...K.....F....
00C0: 89 C8 2E F4 83 9B 90 AD   49 1E B1 A1 DD F6 C7 79  ........I......y
00D0: 89 7F 1E 3F 2E 18 33 D8   90 71 8C 44 86 CF 66 B5  ...?..3..q.D..f.
00E0: D7 89 60 1B 48 C7 CF 9E   A1 AC 0C 3D 6B CA 7A F8  ..`.H......=k.z.
00F0: AD 92 55 9C 4E F7 58 A9   C8 16 4D 48 A3 46 8F D2  ..U.N.X...MH.F..

]
2020-07-10 15:17:59 | == Account created: Account[jid=two-way-tsl-user-OK_6qvoc70124@a.localhost]
2020-07-10 15:17:59 | == creating jaxmpp: account Account[jid=two-way-tsl-user-OK_6qvoc70124@a.localhost], resource: null, host: localhost, connected: false
2020-07-10 15:17:59 | == jaxmpp created, account: Account[jid=two-way-tsl-user-OK_6qvoc70124@a.localhost], isConnected: false
2020-07-10 15:17:59 | [Mutex] waiting for: [registration]
2020-07-10 15:17:59 | two-way-tsl-user-OK :: two-way-tsl-user-OK_6qvoc70124@a.localhost << <features xmlns="http://etherx.jabber.org/streams"><sm xmlns="urn:xmpp:sm:3"/><mechanisms xmlns="urn:ietf:params:xml:ns:xmpp-sasl"/><register xmlns="http://jabber.org/features/iq-register"/><ver xmlns="urn:xmpp:features:rosterver"/><sub xmlns="urn:xmpp:features:pre-approval"/><starttls xmlns="urn:ietf:params:xml:ns:xmpp-tls"><required/></starttls><compression xmlns="http://jabber.org/features/compress"><method>zlib</method></compression></features>
2020-07-10 15:17:59 | two-way-tsl-user-OK :: two-way-tsl-user-OK_6qvoc70124@a.localhost >> <starttls xmlns="urn:ietf:params:xml:ns:xmpp-tls"/>
2020-07-10 15:18:00 | two-way-tsl-user-OK :: two-way-tsl-user-OK_6qvoc70124@a.localhost << <features xmlns="http://etherx.jabber.org/streams"><sm xmlns="urn:xmpp:sm:3"/><auth xmlns="http://jabber.org/features/iq-auth"/><mechanisms xmlns="urn:ietf:params:xml:ns:xmpp-sasl"><mechanism>SCRAM-SHA-512</mechanism><mechanism>SCRAM-SHA-256</mechanism><mechanism>SCRAM-SHA-1</mechanism><mechanism>PLAIN</mechanism><mechanism>ANONYMOUS</mechanism></mechanisms><register xmlns="http://jabber.org/features/iq-register"/><ver xmlns="urn:xmpp:features:rosterver"/><sub xmlns="urn:xmpp:features:pre-approval"/><compression xmlns="http://jabber.org/features/compress"><method>zlib</method></compression></features>
2020-07-10 15:18:00 | two-way-tsl-user-OK :: two-way-tsl-user-OK_6qvoc70124@a.localhost >> <iq to="a.localhost" id="JrkPO5AziAobwgBrdAcrbNY" type="get"><query xmlns="jabber:iq:register"/></iq>
2020-07-10 15:18:00 | two-way-tsl-user-OK :: two-way-tsl-user-OK_6qvoc70124@a.localhost << <iq xmlns="jabber:client" from="a.localhost" type="result" id="JrkPO5AziAobwgBrdAcrbNY"><query xmlns="jabber:iq:register"><instructions>Choose a user name and password for use with this service.

Please also provide your e-mail address (must be valid!) to which we will send confirmation link.</instructions><x xmlns="jabber:x:data" type="form"><title>Account Registration</title><instructions>Choose a user name and password for use with this service.

Please also provide your e-mail address (must be valid!) to which we will send confirmation link.</instructions><field var="FORM_TYPE" type="hidden"><value>jabber:iq:register</value></field><field var="username" label="Username" type="text-single"><required/><value/></field><field var="password" label="Password" type="text-private"><required/><value/></field><field var="email" label="Email (MUST BE VALID!)" type="text-single"><required/><value/></field></x></query></iq>
2020-07-10 15:18:00 | two-way-tsl-user-OK :: two-way-tsl-user-OK_6qvoc70124@a.localhost >> <iq to="a.localhost" id="2AJeFxpUX9BlMQ9snaJCeGL" type="set"><query xmlns="jabber:iq:register"><username>two-way-tsl-user-OK_6qvoc70124</username><password>two-way-tsl-user-OK_6qvoc70124</password><email>eefc2fb2-bea6-456e-8336-b6abe8166a4e@localhost</email></query></iq>
2020-07-10 15:18:00 | two-way-tsl-user-OK :: two-way-tsl-user-OK_6qvoc70124@a.localhost << <iq xmlns="jabber:client" from="a.localhost" type="result" id="2AJeFxpUX9BlMQ9snaJCeGL"/>
2020-07-10 15:18:00 | [Mutex] received everything.
2020-07-10 15:18:00 | [Mutex] isItemNotified: registrationSuccess :: true
2020-07-10 15:18:19 | Disconnected during registration!
2020-07-10 15:18:19 | [Mutex] notify: [registration]
testConnectionWithWrongCertificate 0.491s
2020-07-10 15:18:00 |
2020-07-10 15:18:00 | null / [TestClass name=class tigase.tests.server.TestTwoWayTLS]
2020-07-10 15:18:00 | ------------------------------------
2020-07-10 15:18:00 | == testing connection with WRONG certificate
2020-07-10 15:18:00 | [
[
  Version: V1
  Subject: CN=domain, CN=*.domain, EMAILADDRESS=alice@coffeebean.local, OU=org, O=org, L=tr, ST=kp, C=PL
  Signature Algorithm: SHA1withRSA, OID = 1.2.840.113549.1.1.5

  Key:  Sun RSA public key, 1024 bits
  params: null
  modulus: 170990510347976278198091079301020730631288058277311112279494037636277089393752861305520395076790187677047659727482791805550036913844841912000675618827847688512056356937179090566608100696429600764371049222748543994932086311929315873096617834700985213010134168386562847438583377940346157698488721927333231510823
  public exponent: 65537
  Validity: [From: Fri Jul 10 15:18:00 PDT 2020,
               To: Sat Jul 10 15:18:00 PDT 2021]
  Issuer: CN=domain, CN=*.domain, EMAILADDRESS=alice@coffeebean.local, OU=org, O=org, L=tr, ST=kp, C=PL
  SerialNumber: [    5f08e918]

]
  Algorithm: [SHA1withRSA]
  Signature:
0000: 1E BB DC FC 85 37 24 08   40 46 DC CF 12 6B 2E EA  .....7$.@F...k..
0010: 1F F6 D9 15 88 1C 59 C1   C8 80 FE 24 51 BA 4C ED  ......Y....$Q.L.
0020: 71 43 88 F3 B3 A2 AB FF   7B 8E 5D 7A 48 3F 55 33  qC........]zH?U3
0030: 91 C3 85 20 59 83 35 3C   ED 3C 82 7E F5 FA B0 33  ... Y.5<.<.....3
0040: 16 8E 0E 97 23 51 4A B0   2A 77 6B 60 B9 76 DC 42  ....#QJ.*wk`.v.B
0050: A6 73 47 FE 2A 1B 3B 15   7E 4D 07 6A 1D 6B 44 F8  .sG.*.;..M.j.kD.
0060: F0 46 8E C4 90 38 55 38   0B 72 11 04 0B 1D 24 6B  .F...8U8.r....$k
0070: 23 D8 E8 90 BB BD 3F 27   A2 28 23 51 8D 7F 84 13  #.....?'.(#Q....

]
2020-07-10 15:18:00 | == Account created: Account[jid=two-way-tsl-user-WRONG_qd62050125@a.localhost]
2020-07-10 15:18:00 | == creating jaxmpp: account Account[jid=two-way-tsl-user-WRONG_qd62050125@a.localhost], resource: null, host: localhost, connected: false
2020-07-10 15:18:00 | == jaxmpp created, account: Account[jid=two-way-tsl-user-WRONG_qd62050125@a.localhost], isConnected: false
2020-07-10 15:18:00 | [Mutex] waiting for: [registration]
2020-07-10 15:18:00 | two-way-tsl-user-WRONG :: two-way-tsl-user-WRONG_qd62050125@a.localhost << <features xmlns="http://etherx.jabber.org/streams"><sm xmlns="urn:xmpp:sm:3"/><mechanisms xmlns="urn:ietf:params:xml:ns:xmpp-sasl"/><register xmlns="http://jabber.org/features/iq-register"/><ver xmlns="urn:xmpp:features:rosterver"/><sub xmlns="urn:xmpp:features:pre-approval"/><starttls xmlns="urn:ietf:params:xml:ns:xmpp-tls"><required/></starttls><compression xmlns="http://jabber.org/features/compress"><method>zlib</method></compression></features>
2020-07-10 15:18:00 | two-way-tsl-user-WRONG :: two-way-tsl-user-WRONG_qd62050125@a.localhost >> <starttls xmlns="urn:ietf:params:xml:ns:xmpp-tls"/>
2020-07-10 15:18:00 | Disconnected during registration!
2020-07-10 15:18:00 | [Mutex] notify: [registration]
2020-07-10 15:18:00 | [Mutex] received everything.
2020-07-10 15:18:00 | [Mutex] isItemNotified: registrationSuccess :: false
testConnectionWithoutCertificate 0.052s
2020-07-10 15:18:00 |
2020-07-10 15:18:00 | null / [TestClass name=class tigase.tests.server.TestTwoWayTLS]
2020-07-10 15:18:00 | ------------------------------------
2020-07-10 15:18:00 | == testing connection WITHOUT certificate
2020-07-10 15:18:00 | == Account created: Account[jid=two-way-tsl-user-WITHOUT_rd2yj40126@a.localhost]
2020-07-10 15:18:00 | == creating jaxmpp: account Account[jid=two-way-tsl-user-WITHOUT_rd2yj40126@a.localhost], resource: null, host: localhost, connected: false
2020-07-10 15:18:00 | == jaxmpp created, account: Account[jid=two-way-tsl-user-WITHOUT_rd2yj40126@a.localhost], isConnected: false
2020-07-10 15:18:00 | [Mutex] waiting for: [registration]
2020-07-10 15:18:00 | two-way-tsl-user-WITHOUT :: two-way-tsl-user-WITHOUT_rd2yj40126@a.localhost << <features xmlns="http://etherx.jabber.org/streams"><sm xmlns="urn:xmpp:sm:3"/><mechanisms xmlns="urn:ietf:params:xml:ns:xmpp-sasl"/><register xmlns="http://jabber.org/features/iq-register"/><ver xmlns="urn:xmpp:features:rosterver"/><sub xmlns="urn:xmpp:features:pre-approval"/><starttls xmlns="urn:ietf:params:xml:ns:xmpp-tls"><required/></starttls><compression xmlns="http://jabber.org/features/compress"><method>zlib</method></compression></features>
2020-07-10 15:18:00 | two-way-tsl-user-WITHOUT :: two-way-tsl-user-WITHOUT_rd2yj40126@a.localhost >> <starttls xmlns="urn:ietf:params:xml:ns:xmpp-tls"/>
2020-07-10 15:18:00 | Disconnected during registration!
2020-07-10 15:18:00 | [Mutex] notify: [registration]
2020-07-10 15:18:00 | [Mutex] received everything.
2020-07-10 15:18:00 | [Mutex] isItemNotified: registrationSuccess :: false