EVerest / libiso15118

ISO 15118 library suite
Apache License 2.0
8 stars 5 forks source link

TLS 1.3 EOF error while performing handshake with libiso15118 (segfault) #6

Open FaHaGit opened 8 months ago

FaHaGit commented 8 months ago

ISO Version

ISO15118-20

Describe the bug

Environment: everest-core: https://github.com/EVerest/everest-core/commit/3e5c467546ddfb3341083480ced7e01b0786e92c libiso15118: https://github.com/EVerest/libiso15118/commit/0f34d53737606ab5de783858c06a80521f3a5710

TLS handshake fails with error message 1 when testing with Trialog Testsystem:

Feb 01 10:58:57 tarragon01 manager[20097]: 2024-02-01 10:58:57.484532 [INFO] connector_1:Evs :: EVSE ISO SLAC MATCHED Feb 01 10:58:57 tarragon01 manager[20097]: 2024-02-01 10:58:57.517753 [INFO] connector_1:Evs :: EVSE ISO D-LINK_READY (true) Feb 01 10:59:03 tarragon01 manager[20097]: 2024-02-01 10:59:03.906353 [INFO] connector_1:Evs :: EVSE ISO Change HLC Limits: 11040W/200A, target_voltage 0, actual_voltage 2, hack_bpt false Feb 01 10:59:05 tarragon01 manager[20097]: 2024-02-01 10:59:05.342393 [INFO] connector_1:Evs :: EVSE ISO Change HLC Limits: 11040W/200A, target_voltage 0, actual_voltage 0, hack_bpt false Feb 01 10:59:05 tarragon01 manager[20105]: 2024-02-01 10:59:05.833929 [INFO] iso15118_charge :: Got SDP request Feb 01 10:59:06 tarragon01 manager[20105]: 2024-02-01 10:59:06.864023 [ERRO] iso15118_charge virtual void module::charger::ISO15118_chargerImpl::ready() :: D20Evse chrashed: Failed to mbedtls_ssl_handshake() (SSL - The connection indicated an EOF) Feb 01 10:59:06 tarragon01 manager[20105]: 2024-02-01 10:59:06.864738 [INFO] iso15118_charge :: Shutting down SDP server!

TLS handshake fails with error message 2:

Feb 01 10:58:23 tarragon01 manager[12619]: 2024-02-01 10:58:23.580968 [INFO] connector_1:Evs :: EVSE ISO SLAC MATCHED Feb 01 10:58:23 tarragon01 manager[12619]: 2024-02-01 10:58:23.604079 [INFO] connector_1:Evs :: EVSE ISO D-LINK_READY (true) Feb 01 10:58:29 tarragon01 manager[12626]: 2024-02-01 10:58:29.900146 [INFO] iso15118_charge :: Got SDP request Feb 01 10:58:29 tarragon01 manager[12626]: 2024-02-01 10:58:29.912135 [ERRO] iso15118_charge virtual void module::charger::ISO15118_chargerImpl::ready() :: D20Evse chrashed: Failed to mbedtls_net_bind() (NET - Binding of the socket failed) Feb 01 10:58:29 tarragon01 manager[12626]: 2024-02-01 10:58:29.919936 [INFO] iso15118_charge :: Shutting down SDP

To Reproduce

Start of a TLS 1.3 session with Trialog Testsystem

Anything else?