18 lines
655 B
Rust
18 lines
655 B
Rust
//! OS certificate-verifier initialization only; Git/TLS policy stays in storage.
|
|
//! The JNI macro supplies a scoped valid environment and catches boundary panics;
|
|
//! rustls retains global Context/class-loader references before this scope ends.
|
|
use jni::{Env, objects::JObject};
|
|
|
|
const _: jni::NativeMethod = jni::native_method! {
|
|
java_type = "de.rfc1437.ironstorage.bridge.NativeTls",
|
|
extern fn initialize(context: JObject),
|
|
};
|
|
|
|
fn initialize<'local>(
|
|
env: &mut Env<'local>,
|
|
_this: JObject<'local>,
|
|
context: JObject<'local>,
|
|
) -> Result<(), jni::errors::Error> {
|
|
rustls_platform_verifier::android::init_with_env(env, context)
|
|
}
|