* [ath9k-devel] Cryptography of ath9k driver
@ 2016-10-26 6:53 Jeon
2016-10-26 10:38 ` Janusz Dziedzic
0 siblings, 1 reply; 4+ messages in thread
From: Jeon @ 2016-10-26 6:53 UTC (permalink / raw)
To: ath9k-devel
I am investigating how ath9k performs cryptography.
In slide 15 of DEFCON conference 2014 (link
<https://docs.google.com/presentation/d/1CofNlbHs2bLdJuW3VACzAImqesGQoktUTXS6zKgDDKI/edit#slide=id.g371192f19_070>),
it says, ath9k performs cryptography a on software side.
On the other hand, when I look into ath9k source codes, I found somethings
like below:
ath9k/common.c:162-166:
if (ah->sw_mgmt_crypto_rx &&
(rxs->flag & RX_FLAG_DECRYPTED) &&
ieee80211_is_mgmt(fc))
/* Use software decrypt for management frames. */
rxs->flag &= ~RX_FLAG_DECRYPTED;
As I understand, ath9k can choose hw/sw cryptography for management frames.
However, what about data frames? I couldn't find any clue about
cryptography for data frames.
Can I take it as ath9k already performs software cryptography for data
frames and shifts the responsibility of cryptography to mac80211 driver?
And exceptionally for management frames, can ath9k choose hw/sw
cryptography?
Regards,
Jeon.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ath9k.org/pipermail/ath9k-devel/attachments/20161026/e8cc3864/attachment.htm
^ permalink raw reply [flat|nested] 4+ messages in thread
* [ath9k-devel] Cryptography of ath9k driver
2016-10-26 6:53 [ath9k-devel] Cryptography of ath9k driver Jeon
@ 2016-10-26 10:38 ` Janusz Dziedzic
2016-10-26 11:10 ` Jeon
0 siblings, 1 reply; 4+ messages in thread
From: Janusz Dziedzic @ 2016-10-26 10:38 UTC (permalink / raw)
To: ath9k-devel
On 26 October 2016 at 08:53, Jeon <sjeon87+ath9k@gmail.com> wrote:
> I am investigating how ath9k performs cryptography.
>
> In slide 15 of DEFCON conference 2014 (link
> <https://docs.google.com/presentation/d/1CofNlbHs2bLdJuW3VACzAImqesGQoktUTXS6zKgDDKI/edit#slide=id.g371192f19_070>),
> it says, ath9k performs cryptography a on software side.
>
> On the other hand, when I look into ath9k source codes, I found somethings
> like below:
>
> ath9k/common.c:162-166:
>
> if (ah->sw_mgmt_crypto_rx &&
> (rxs->flag & RX_FLAG_DECRYPTED) &&
> ieee80211_is_mgmt(fc))
> /* Use software decrypt for management frames. */
> rxs->flag &= ~RX_FLAG_DECRYPTED;
>
> As I understand, ath9k can choose hw/sw cryptography for management
> frames. However, what about data frames? I couldn't find any clue about
> cryptography for data frames.
>
> Can I take it as ath9k already performs software cryptography for data
> frames and shifts the responsibility of cryptography to mac80211 driver?
> And exceptionally for management frames, can ath9k choose hw/sw
> cryptography?
>
>
modinfo ath9k (check nohwcrypt param)
BR
Janusz
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ath9k.org/pipermail/ath9k-devel/attachments/20161026/d163fbd4/attachment.htm
^ permalink raw reply [flat|nested] 4+ messages in thread
* [ath9k-devel] Cryptography of ath9k driver
2016-10-26 10:38 ` Janusz Dziedzic
@ 2016-10-26 11:10 ` Jeon
2016-11-05 5:08 ` Adrian Chadd
0 siblings, 1 reply; 4+ messages in thread
From: Jeon @ 2016-10-26 11:10 UTC (permalink / raw)
To: ath9k-devel
Thanks for response.
Well, I mean, are those hardware cryptography and nohwcrypt modparam
applying only to management frames (i.e., are data frames already being
en/decrypted by using software cryptography in mac/ieee80211 kernel module?)
Regards,
Jeon.
On Wed, Oct 26, 2016 at 7:38 PM, Janusz Dziedzic <janusz.dziedzic@tieto.com>
wrote:
>
>
> On 26 October 2016 at 08:53, Jeon <sjeon87+ath9k@gmail.com> wrote:
>
>> I am investigating how ath9k performs cryptography.
>>
>> In slide 15 of DEFCON conference 2014 (link
>> <https://docs.google.com/presentation/d/1CofNlbHs2bLdJuW3VACzAImqesGQoktUTXS6zKgDDKI/edit#slide=id.g371192f19_070>),
>> it says, ath9k performs cryptography a on software side.
>>
>> On the other hand, when I look into ath9k source codes, I found
>> somethings like below:
>>
>> ath9k/common.c:162-166:
>>
>> if (ah->sw_mgmt_crypto_rx &&
>> (rxs->flag & RX_FLAG_DECRYPTED) &&
>> ieee80211_is_mgmt(fc))
>> /* Use software decrypt for management frames. */
>> rxs->flag &= ~RX_FLAG_DECRYPTED;
>>
>> As I understand, ath9k can choose hw/sw cryptography for management
>> frames. However, what about data frames? I couldn't find any clue about
>> cryptography for data frames.
>>
>> Can I take it as ath9k already performs software cryptography for data
>> frames and shifts the responsibility of cryptography to mac80211 driver?
>> And exceptionally for management frames, can ath9k choose hw/sw
>> cryptography?
>>
>>
> modinfo ath9k (check nohwcrypt param)
>
> BR
> Janusz
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ath9k.org/pipermail/ath9k-devel/attachments/20161026/2a3f4ada/attachment.htm
^ permalink raw reply [flat|nested] 4+ messages in thread
* [ath9k-devel] Cryptography of ath9k driver
2016-10-26 11:10 ` Jeon
@ 2016-11-05 5:08 ` Adrian Chadd
0 siblings, 0 replies; 4+ messages in thread
From: Adrian Chadd @ 2016-11-05 5:08 UTC (permalink / raw)
To: ath9k-devel
hi,
person who gave talk here :)
so the mac does do wep, tkip, ccmp encryption. the mfp frames use
another encryption type that the mac doesn't do, so it is then done in
software.
each keycache entry in mac80211 tags things as hw or sw handled.
it clears that flag so mac80211 doesn't attempt to treat it as
decrypted by hardware. it overrides whatever the RX path has already
set up in that flag word.
-a
On 26 October 2016 at 04:10, Jeon <sjeon87+ath9k@gmail.com> wrote:
> Thanks for response.
>
> Well, I mean, are those hardware cryptography and nohwcrypt modparam
> applying only to management frames (i.e., are data frames already being
> en/decrypted by using software cryptography in mac/ieee80211 kernel module?)
>
> Regards,
> Jeon.
>
>
> On Wed, Oct 26, 2016 at 7:38 PM, Janusz Dziedzic <janusz.dziedzic@tieto.com>
> wrote:
>>
>>
>>
>> On 26 October 2016 at 08:53, Jeon <sjeon87+ath9k@gmail.com> wrote:
>>>
>>> I am investigating how ath9k performs cryptography.
>>>
>>> In slide 15 of DEFCON conference 2014 (link), it says, ath9k performs
>>> cryptography a on software side.
>>>
>>> On the other hand, when I look into ath9k source codes, I found
>>> somethings like below:
>>>
>>> ath9k/common.c:162-166:
>>>
>>> if (ah->sw_mgmt_crypto_rx &&
>>> (rxs->flag & RX_FLAG_DECRYPTED) &&
>>> ieee80211_is_mgmt(fc))
>>> /* Use software decrypt for management frames. */
>>> rxs->flag &= ~RX_FLAG_DECRYPTED;
>>>
>>> As I understand, ath9k can choose hw/sw cryptography for management
>>> frames. However, what about data frames? I couldn't find any clue about
>>> cryptography for data frames.
>>>
>>> Can I take it as ath9k already performs software cryptography for data
>>> frames and shifts the responsibility of cryptography to mac80211 driver? And
>>> exceptionally for management frames, can ath9k choose hw/sw cryptography?
>>>
>>
>> modinfo ath9k (check nohwcrypt param)
>>
>> BR
>> Janusz
>
>
>
> _______________________________________________
> ath9k-devel mailing list
> ath9k-devel at lists.ath9k.org
> https://lists.ath9k.org/mailman/listinfo/ath9k-devel
>
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2016-11-05 5:08 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-10-26 6:53 [ath9k-devel] Cryptography of ath9k driver Jeon
2016-10-26 10:38 ` Janusz Dziedzic
2016-10-26 11:10 ` Jeon
2016-11-05 5:08 ` Adrian Chadd
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).