* In UA_CertificateVerification_VerifyApplicationURI()
set initial subjectURI to UA_STRING_NULL, may be no urn entry in certificate
* Fix problem, if UA_OpenSSL_LoadCertificate() fails in UA_ChannelModule_New_Context()
* Add OpenSSL3.0 support
This change set adds a new function UA_OpenSSL_RSA_Key_Size() to get
the RSA key size, re-writes the function
UA_Openssl_RSA_Private_Decrypt() by using the high level APIs of
OpenSSL3.0, add a new function UA_RSA_Generate_Key() to generate
a RSA key.
No build warning with OpenSSL3.0 and OpenSSL1.1.1f.
* Build & Test with OpenSSL3.0 in Ubuntu22.04
- Changed ethertype from LLC to ETHERTYPE_UADP(0xb62c)
according to pubsub specification
- Handled the padding bytes in the src file
Signed-off-by: Keerthivasan Alagarsamy Senthilkumaran <keerthivasan.as@kalycito.com>
Change-Id: I0785cc259a595cad259273c844ca78942c5ae70c
* Fixed build for Embarcdero C++Builder 10.4/clang
* Fix invalid order of parameters for gmtime_s in arch/win32/ua_clock.c
* Update ua_architecture.h
Fix MS build (again)...
* Fix parameter order of gmtime_s() for CodeGear and MSVC
* Fix OpenSSL V1.1 API compatibility
Co-authored-by: Julius Pfrommer <jpfr@users.noreply.github.com>
- Resolved 9 failure test cases in server_ctt running with OpenSSL
security policy
- Resolved 002.js, 010.js, 029.js, 042.js, 043.js, 044.js, 045.js and
047.js test cases in Security Certificate Validation Conformance Unit
- Resolved Err-003.js test case in Session Base Conformance Unit
Signed-off-by: divyaprasanth <divyaprasanth@kalycito.com>
Change-Id: I4bd0e6c744229e1ce1a83a95a1a9a403875bf687
Co-authored-by: Julius Pfrommer <jpfr@users.noreply.github.com>
UA_PubSubChannelEthernet_receive() returns an uninitialized value
(retval), if there is more data available than fits into the
message buffer.
Control flow in case of the error:
Receive buffer size is 4096 - see UA_ReaderGroup_subscribeCallback.
timeout > 0
select resultsize > 0
recvmsg datalen > 0
remainingMessageLength >= 1496 -> false -> there is still more data
This publisher is a complement to pubsub_interrupt_publish.c. It is a VxWorks
specific implementation with VxWorks-native TSN features and can be applied to
hard realtime scenarios.
There is a small typo in include/open62541/plugin/securitypolicy.h, plugins/crypto/openssl/ua_openssl_aes128sha256rsaoaep.c, plugins/crypto/openssl/ua_openssl_basic256.c, plugins/crypto/openssl/ua_openssl_basic256sha256.c.
Should read `endpoint` rather than `endpoit`.
GCC-10 reports the following error:
In function ‘snprintf’,
inlined from ‘UA_PubSubChannelEthernetETF_open’ at /root/open62541/plugins/ua_pubsub_ethernet_etf.c:195:5,
inlined from ‘TransportLayerEthernetETF_addChannel’ at /root/open62541/plugins/ua_pubsub_ethernet_etf.c:638:40:
/usr/include/bits/stdio2.h:67:10: warning: ‘__builtin___snprintf_chk’ specified bound 40 exceeds destination size 16 [-Wstringop-overflow=]
The same is true for the XDP version. Fix it.
Signed-off-by: Michael Walle <michael.walle@kontron.com>
* Fix memory leak in UA_HistoryDataBackend_Memory
* Fix uninitialized memory in the default history data gathering plugin
After extending the memory block with realloc, the additional memory is
not initialized with null bytes.
If UA_ENABLE_ENCRYPTION_MBEDTLS is set, SecurityPolicy None will still
just copy the certificate data. If the input is PEM, the trailing null
byte is not added and mbedTLS will fail to parse the data.
This breaks the application URI check on server start.
In case of UA_ENABLE_ENCRYPTION_OPENSSL, there is a similar problem
if the PEM data is just copied into the local certificate byte string.
- For Multiple receive implementation
- Tested using tutorial pubsub
- Unit test cases for multiple receive
Signed-off-by: Keerthivasan Alagarsamy Senthilkumaran <keerthivasan.as@kalycito.com>
Change-Id: I0164487f4c6ae03cf910c970847e6314dd21491a
- Handled send and receive api of ethernet
for 802.3 packets
Signed-off-by: Keerthivasan Alagarsamy Senthilkumaran <keerthivasan.as@kalycito.com>
Change-Id: I4f9edb91839836ebe8c3ff64b07f91ca85c56706
* Add null terminator before parsing certificates and keys
mbedTLS expects PEM data to be null terminated, the length
parameter must include the null terminator.
By adding the null terminator inside open62541, an application
doesn't have to care what type of certificate or key is used.
* Extend encryption tests
- Add test for security policy Basic256
- Add test with PEM encoded certificate and key
* Fix amalgamation build for ua_pki_default.c
Including securitypolicy_mbedtls_common.h is not possible because
it is added to the amalgamation after ua_pki_default.c
* Add PEM support for the OpenSSL plugins
PEM is permitted for
- Private key
- CRL
- Trusted certificates
- Issuer certificates
* OpenSSL: Load the private key in a central place in the security policies
This is a preparation for the support of password protected private keys.