initLogging now takes logDir param matching Rust entry point. dumpLogs takes logDir+baseDir params matching Rust. Removed unused generateSoftwareKeyPair declaration. Added buffer bounds checks in parseNativeResult to prevent OOM on malformed native output.