|
|
|
|
@ -33,6 +33,7 @@ use suricata_sys::sys::{
|
|
|
|
|
|
|
|
|
|
pub(super) static mut ALPROTO_SSH: AppProto = ALPROTO_UNKNOWN;
|
|
|
|
|
static HASSH_ENABLED: AtomicBool = AtomicBool::new(false);
|
|
|
|
|
static HASSH_DISABLED: AtomicBool = AtomicBool::new(false);
|
|
|
|
|
|
|
|
|
|
static mut ENCRYPTION_BYPASS_ENABLED: EncryptionHandling =
|
|
|
|
|
EncryptionHandling::ENCRYPTION_HANDLING_TRACK_ONLY;
|
|
|
|
|
@ -585,7 +586,9 @@ pub unsafe extern "C" fn SCRegisterSshParser() {
|
|
|
|
|
|
|
|
|
|
#[no_mangle]
|
|
|
|
|
pub extern "C" fn SCSshEnableHassh() {
|
|
|
|
|
HASSH_ENABLED.store(true, Ordering::Relaxed)
|
|
|
|
|
if !HASSH_DISABLED.load(Ordering::Relaxed) {
|
|
|
|
|
HASSH_ENABLED.store(true, Ordering::Relaxed)
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
#[no_mangle]
|
|
|
|
|
@ -593,6 +596,11 @@ pub extern "C" fn SCSshHasshIsEnabled() -> bool {
|
|
|
|
|
hassh_is_enabled()
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
#[no_mangle]
|
|
|
|
|
pub extern "C" fn SCSshDisableHassh() {
|
|
|
|
|
HASSH_DISABLED.store(true, Ordering::Relaxed)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
#[no_mangle]
|
|
|
|
|
pub extern "C" fn SCSshEnableBypass(mode: EncryptionHandling) {
|
|
|
|
|
unsafe {
|
|
|
|
|
|