Hi everyone,
    I'm trying to encrypt the frames under the monitor mode, using a 5414 card.
    First, I tried the "iwconfig ath0 key [3] s:passwd" & the "iwconfig ath0 key [3] s:passwd open" on the sender. But the receiver can still get the pkt without decryption.
    While if I exec the "iwconfig ath0 key [3] s:passwd" & the "iwconfig ath0 key [3] s:passwd open" on both the sender and the receiver, the receiver cannot get any pkts at all.

    After that, I read the openhal and found a series of "key table (WEP)" registers. From the "key table" macros and functions, I can decide that the key table has 128 entries. And one entry consists of the following:
    bits 0~159 is the key
    bits 160~162 is the encryption type, and I want the AES, type 0x5
    bit 163 is the antenna, and I found nothing related with this bit in the openhal
    bits 192~238 is the MAC, splitting to 32bits low and 16bits high, and I thought that it's the dest MAC
    bit 238 is the VALID flag
   
    According to the above conclusions, I made a ioctl to set the regs, including the key, the type, the MAC address, and the valid flag.
    However, after doing that, the receiver can still get the pkts without decryption.
    The bits AR5K_DIAG_SW_DIS_ENC & AR5K_DIAG_SW_DIS_DEC have been set to 0.

    So does anyone know how to encrypt the pkts under the monitor mode?

    Any suggestions will be appreciated.
--
------------------------------------------------------
A perfect night!
Welcome to Beijing~ ^_^
--------------------------------------------------------
Best wishes,
Lrj, NCI, China