add node-based BSL list helpers and migrate shared-list readers off curr-mutating macros
precompute DN UTF-8 during parse and reuse cached values in X.509 compare/verify
clean up app UIO ownership handling and expand PKI/TLS regression coverage
Signed-off-by: Dongjianwei001 <dongjianwei1@huawei.com>
Co-authored-by: Ooohui<zhanghui160@huawei.com>
# message auto-generated for no-merge-commit merge:
!921 merge main into main
fix: Standardize function naming and error handling in the apps module
Created-by: Ooohui
Commit-by: Ooohui
Merged-by: liwei3013
Description: fix: Standardize function naming and error handling in the apps module
See merge request: openHiTLS/openhitls!921
Signed-off-by: Dongjianwei001 <dongjianwei1@huawei.com>
Co-authored-by: hs6246<zhengzeyang@huawei.com>
# message auto-generated for no-merge-commit merge:
!887 merge main into main
fix:Refactor some functions in app module.
Created-by: hs6246
Commit-by: hs6246
Merged-by: liwei3013
Description: fix:Refactor some functions in app module.
See merge request: openHiTLS/openhitls!887
Signed-off-by: Dongjianwei001 <dongjianwei1@huawei.com>
- Implement prime number generation and primality testing
- Support decimal and hexadecimal input/output formats
- Add safe prime generation option
- Include 15 comprehensive test cases with cross-platform support
- Add command-line interface with options: -generate, -bits, -safe, -hex, -checks
Cherry-picked from: https://gitcode.com/openHiTLS/openhitls/merge_requests/856
Signed-off-by: Dongjianwei001 <dongjianwei1@huawei.com>
**Core Platform Support:**
- Add Darwin/macOS platform detection and conditional compilation
- Implement platform-specific library extensions (.dylib for macOS, .so for Linux)
- Enhanced dynamic library loading with cross-platform error handling
- Platform-optimized time functions (clock_gettime_nsec_np for macOS)
- Add App module support for Darwin/macOS
**Threading & Synchronization:**
- BSL: Migrate from simple integer flags to proper pthread_once_t implementation
- Add BSL_SAL_OnceControl type with platform-specific implementations
- Implement thread-safe one-time initialization across platforms
- Fix memory initialization patterns for thread-once controls
**Build System Improvements:**
- Remove GNU ld-specific flags for test-framework use c function pointer replace or `stub_utils.h` to hook target function
- Boundcheck components will linked as static library for tests, reduce tests dynamic library deps
- Update CMake configurations for Darwin support
**Test Framework Enhancements:**
- Replace jmp_buf with sigjmp_buf for better signal handling
- Update time handling to avoid platform-specific gmtime issues
- Improve entropy test stability across platforms
- Add proper RAND initialization/deinitialization
**Entropy & Cryptographic Updates:**
- Temporarily disable CPU jitter entropy on macOS (pending validation)
- Add cross-platform entropy source management
- Update DRBG configuration for improved compatibility
- Enhance hardware entropy detection and handling
**Network & I/O:**
- Extend POSIX network functions to support both Linux and Darwin
- Add file accessibility checks before dynamic loading
- Improve error handling for symbol resolution across platforms
- Update socket and I/O operations for cross-platform compatibility
Cherry-picked from: https://gitcode.com/openHiTLS/openhitls/merge_requests/677
Signed-off-by: Dongjianwei001 <dongjianwei1@huawei.com>
Co-authored-by: dny<duanningyan@huawei.com>
# message auto-generated for no-merge-commit merge:
merge gm into main
App tlcp support use p12 sign key.
Created-by: dny
Commit-by: dny
Merged-by: liwei3013
Description: App tlcp support use p12 sign key.
See merge request: openHiTLS/openhitls!585
Signed-off-by: Dongjianwei001 <dongjianwei1@huawei.com>
Co-authored-by: dny<duanningyan@huawei.com>
# message auto-generated for no-merge-commit merge:
merge gm into main
App tlcp add sm mode.
Created-by: dny
Commit-by: dny
Merged-by: liwei3013
Description: App tlcp add sm mode.
See merge request: openHiTLS/openhitls!579
Signed-off-by: Dongjianwei001 <dongjianwei1@huawei.com>
Co-authored-by: tianshenqi<tianshenqi@h-partners.com>
# message auto-generated for no-merge-commit merge:
merge TLS-cut into main
feat:TLS protocol features related to SM series
Created-by: tianshenqi
Commit-by: tianshenqi
Merged-by: liwei3013
Description: feat: Add command-line TLS protocol function.
Merge branch 'main' of gitcode.com:tianshenqi/openhitls into TLS
feat:TLS protocol features related to SM series
See merge request: openHiTLS/openhitls!507
Signed-off-by: Dongjianwei001 <dongjianwei1@huawei.com>