Enhance logging framework and fix build issues

- Rename SecurityLogger to SecureLogger for better clarity
- Add file:line:function tracking to all log entries
- Optimize logging with pre-compiled regex patterns and NSCache
- Add comprehensive logging for critical protocol flow points
- Fix iOS entitlements to include Bluetooth permission
- Fix VersionHello field name and optional chaining issues
- Fix Package.swift resource warnings
- Fix test compilation errors with proper type annotations
This commit is contained in:
jack
2025-07-22 15:40:13 +02:00
parent 49daa995cc
commit aaa7e2bf28
13 changed files with 269 additions and 112 deletions
@@ -41,7 +41,7 @@ class VersionNegotiationScenarioTests: XCTestCase {
func testMixedVersionNetwork() {
// Scenario: Network with mixed client versions
let clients = [
let clients: [[UInt8]] = [
[1], // Old client
[1, 2], // Mid-version client
[1, 2, 3] // New client
@@ -181,13 +181,13 @@ class VersionNegotiationScenarioTests: XCTestCase {
let clientCapabilities = ["noise", "compression", "multipath"]
let serverCapabilities = ["noise", "compression", "federation"]
let hello = VersionHello(
_ = VersionHello(
clientVersion: "1.0.0",
platform: "iOS",
capabilities: clientCapabilities
)
let ack = VersionAck(
_ = VersionAck(
agreedVersion: 1,
serverVersion: "1.0.0",
platform: "macOS",