Open petermetz opened 3 years ago
Never seen this one again since the time it was opened. Assuming to have been implicitly fixed by dependency upgrades along the way.
Re-opening because it just popped up again, out of the blue...
# Subtest: ./packages/cactus-cmd-api-server/src/test/typescript/unit/config/self-signed-certificate-generator/certificates-work-for-mutual-tls.test.ts
# works with HTTPS NodeJS module
ok 1 class present on API surface
ok 2 Instantiated SelfSignedCertificateGenerator OK.
ok 3 serverCert truthy
ok 4 serverCert.certificatePem truthy
ok 5 serverCert.privateKeyPem truthy
ok 6 serverCert.certificate truthy
ok 7 serverCert.keyPair truthy
ok 8 clientCert truthy
ok 9 clientCert.certificatePem truthy
ok 10 clientCert.privateKeyPem truthy
ok 11 clientCert.certificate truthy
ok 12 clientCert.keyPair truthy
ok 13 Server cert verified client cert OK
ok 14 HTTPS Server object truthy
ok 15 HTTPS Server is indeed listening
ok 16 HTTPS Server provided truthy AddressInfo
ok 17 HTTPS Server provided truthy AddressInfo.port
[2022-01-21T03:16:25.071Z] DEBUG (test-generates-working-certificates): AddressInfo for test HTTPS server: {"address":"127.0.0.1","family":"IPv4","port":37883}
not ok 18 Error: error:0D0E20DD:asn1 encoding routines:c2i_ibuf:illegal padding
---
operator: error
at: bound (/home/runner/work/cactus/cactus/node_modules/tape-promise/node_modules/onetime/index.js:30:12)
stack: |-
Error: error:0D0E20DD:asn1 encoding routines:c2i_ibuf:illegal padding
at node:internal/tls/secure-context:65:13
at Array.forEach (<anonymous>)
at setCerts (node:internal/tls/secure-context:63:3)
at configSecureContext (node:internal/tls/secure-context:152:5)
at Object.createSecureContext (node:_tls_common:116:3)
at Object.connect (node:_tls_wrap:1621:48)
at Agent.createConnection (node:https:143:22)
at Agent.createSocket (node:_http_agent:341:26)
at Agent.addRequest (node:_http_agent:292:10)
at new ClientRequest (node:_http_client:305:16)
...
Bail out! Error: error:0D0E20DD:asn1 encoding routines:c2i_ibuf:illegal padding
Bail out! Error: error:0D0E20DD:asn1 encoding routines:c2i_ibuf:illegal padding
Spotted this (or something very similar) again here: 2023-08-11T21-06-36-cacti-ci-connector-fabric-socketio-illegal-padding-crash.test.log
Describe the bug
A quite strange flake. 3 out of the 4 CI runs succeeded for my PR but this one failed with the error mentioned in the subject while executing the test at
./packages/cactus-cmd-api-server/src/test/typescript/integration/runtime-plugin-imports.test.ts
To Reproduce
Not sure, could be some race condition internal to NodeJS itself. I doubt we'll be able to reproduce it to be honest.
Expected behavior
Test does not fail.
Logs/Stack traces
https://github.com/petermetz/cactus/runs/2071676202?check_suite_focus=true#step:10:179
Screenshots
If applicable, add screenshots to help explain your problem.
Cloud provider or hardware configuration: Are you running the software on a dev machine or somewhere in the cloud?
Operating system name, version, build:
Ubuntu 20.04 LTS
Hyperledger Cactus release version or commit (git rev-parse --short HEAD):
main
Hyperledger Cactus Plugins/Connectors Used
N/A
Additional context
This came out during the development of the Fabric contract deployment endpoint, but this fact is suspected to be a coincidence and that the issue itself has nothing to do with the Fabric connector or its tests.
cc: @takeutak @sfuji822 @hartm @jonathan-m-hamilton @AzaharaC @jordigiam @kikoncuo