Scripting the sniffer built into Wireless Diagnostics

Discussion in 'Mac Programming' started by TenthAlmond, Aug 24, 2017.

  1. TenthAlmond macrumors newbie

    TenthAlmond

    Joined:
    Aug 24, 2017
    #1
    I'm interested in using the built-in wireless sniffer (accessible from Wireless Diagnostics by pressing Cmd-Opt-6) as a part of a script. Is there a way to control it via scripting, maybe AppleScript?

    I only need to start the sniffer and to be able to change the channel and bandwidth.

    Can the interface be scripted? Does Wireless Diagnostics offer any Apple events?
     
  2. cruisin macrumors 6502a

    cruisin

    Joined:
    Apr 1, 2014
    Location:
    Canada
    #2
    The script editor doesn't have a dictionary for wireless diagnostics, which likely means that it won't support scripting. Perhaps wireshark has some terminal commands that can be scripted?
     
  3. msephton macrumors 6502

    msephton

    Joined:
    Jan 6, 2004
    Location:
    Cornwall, UK
    #3
    Even if there's no dictionary can't you script through UI elements?
     
  4. TenthAlmond thread starter macrumors newbie

    TenthAlmond

    Joined:
    Aug 24, 2017
    #4
    Thanks for making me aware that scripting UI elements directly was an option! I didn't know.

    I ended up doing as cruisin recommended, scripting Wireshark via tshark instead.
     

Share This Page

3 August 24, 2017