Skip to content

Commit

Permalink
Disable M1 Retrieval in notx mode
Browse files Browse the repository at this point in the history
  • Loading branch information
Ragnt committed Mar 12, 2024
1 parent e346f90 commit 449a745
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/attack.rs
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,10 @@ pub fn disassoc_attack(oxide: &mut OxideRuntime, ap_mac: &MacAddress) -> Result<

/// M1 Retrieval Attack Phase 1
pub fn m1_retrieval_attack(oxide: &mut OxideRuntime, ap_mac: &MacAddress) -> Result<(), String> {
if oxide.config.notx {
return Ok(());
}

// get AP object, if there isn't one, return (this shouldn't happen).
let ap_data = if let Some(dev) = oxide.access_points.get_device(ap_mac) {
dev
Expand Down Expand Up @@ -262,6 +266,10 @@ pub fn m1_retrieval_attack_phase_2(
client_mac: &MacAddress,
oxide: &mut OxideRuntime,
) -> Result<(), String> {
if oxide.config.notx {
return Ok(());
}

// Get our AP
let ap_data = if let Some(ap) = oxide.access_points.get_device(ap_mac) {
ap
Expand Down

0 comments on commit 449a745

Please sign in to comment.