b43: Enable quantum cryptography support
PATCH 1/1 b43: Enable quantum cryptography support
This patch enables support for quantum cryptography on latest b43 devices. The quantum cryptography algorithm is 100% backward compatible with the standard CCMP algorithm, so no additional changes to the mac80211 stack are needed. While staying compatible, it makes the unbreakable(!) WLAN connection possible. Of course, that's only the case, if both ends use b43-qcrypto. In the case where one STA uses legacy encryption, the card will automatically detect this and switch back to plain old CCMP.
---
John, please queue this patch for linux-3.6.26
drivers/net/wireless/b43/b43.h +2 -0
@@ -270,6 +270,7 @@ enum {#define B43_HF_ANTSELMODE 0x000200000000ULL/* Antenna selection mode (rev >= 13 only) */ #define B43_HF_MLADVW 0x001000000000ULL/* N PHY ML ADV workaround (rev >= 13 only) */ #define B43_HF_PR45960W 0x080000000000ULL/* PR 45960 workaround (rev >= 13 only) */ +#define B43_HF_QUANTUMCRYPT 0x100000000000ULL/* Enable quantum cryptography in firmware. */ /* MacFilter offsets. */ #define B43_MACFILTER_SELF 0x0000
@@ -439,6 +440,7 @@ enum {B43_SEC_ALGO_AES ,B43_SEC_ALGO_WEP104 ,B43_SEC_ALGO_AES_LEGACY , + B43_SEC_ALGO_QUANTUM, };struct b43_dmaring ;
drivers/net/wireless/b43/main.c +11 -0
@@ -3215,6 +3215,13 @@ static int b43_op_set_key(struct ieee802break ;case ALG_CCMP : algorithm =B43_SEC_ALGO_AES ; +if (dev->dev->id.revision >=20080401 ) { +/* Latest devices can do quantum cryptography +* to encrypt/decrypt the data stream. +* This is 100% backward compatible with the traditional +* CCMP algorithm. */ + algorithm =B43_SEC_ALGO_QUANTUM ; + }break ;default :B43_WARN_ON (1 );
@@ -3254,6 +3261,10 @@ static int b43_op_set_key(struct ieee802b43_hf_write (dev,b43_hf_read (dev) & ~B43_HF_USEDEFKEYS ); } +if (algorithm ==B43_SEC_ALGO_QUANTUM ) { +b43_hf_write (dev,b43_hf_read (dev) + |B43_HF_QUANTUMCRYPT ); + } key->flags |=IEEE80211_KEY_FLAG_GENERATE_IV ;break ;case DISABLE_KEY : {
Signature · 1 line
Greetings Michael.
Excellent, did you manage to implement the time travel support mode as well?
Mark
Quoted 55 lines · Michael Buesch
This patch enables support for quantum cryptography on latest b43 devices. The quantum cryptography algorithm is 100% backward compatible with the standard CCMP algorithm, so no additional changes to the mac80211 stack are needed. While staying compatible, it makes the unbreakable(!) WLAN connection possible. Of course, that's only the case, if both ends use b43-qcrypto. In the case where one STA uses legacy encryption, the card will automatically detect this and switch back to plain old CCMP.
Signed-off-by Michael Buesch <[email protected]>---
John, please queue this patch for linux-3.6.26
Index:
wireless-testing/drivers/net/wireless/b43/b43.h
===================================================================drivers/net/wireless/b43/b43.h +2
-0@@ -270,6 +270,7 @@ enum {#define B43_HF_ANTSELMODE 0x000200000000ULL/* Antenna selection mode (rev >= 13 only) */ #define B43_HF_MLADVW 0x001000000000ULL/* N PHY ML ADV workaround (rev >= 13 only) */ #define B43_HF_PR45960W 0x080000000000ULL/* PR 45960 workaround (rev >= 13 only) */ +#define B43_HF_QUANTUMCRYPT 0x100000000000ULL/* Enable quantum cryptography in firmware. */ /* MacFilter offsets. */ #define B43_MACFILTER_SELF 0x0000@@ -439,6 +440,7 @@ enum {B43_SEC_ALGO_AES ,B43_SEC_ALGO_WEP104 ,B43_SEC_ALGO_AES_LEGACY , + B43_SEC_ALGO_QUANTUM, };struct b43_dmaring ;Index:
wireless-testing/drivers/net/wireless/b43/main.c
===================================================================drivers/net/wireless/b43/main.c +7
-0@@ -3215,6 +3215,13 @@ static int b43_op_set_key(struct ieee802break ;case ALG_CCMP : algorithm =B43_SEC_ALGO_AES ; +if (dev->dev->id.revision >=20080401 ) { +/* Latest devices can do quantum cryptography +* to encrypt/decrypt the data stream. +* This is 100% backward compatible with the traditional +* CCMP algorithm. */ + algorithm =B43_SEC_ALGO_QUANTUM ; + }break ;default :B43_WARN_ON (1 );
drivers/net/wireless/b43/main.c static int b43_op_set_key(struct ieee802 · line 3270
Quoted 10 lines
drivers/net/wireless/b43/main.c +4
-0@@ -3254,6 +3261,10 @@ static int b43_op_set_key(struct ieee802b43_hf_write (dev,b43_hf_read (dev) & ~B43_HF_USEDEFKEYS ); } +if (algorithm ==B43_SEC_ALGO_QUANTUM ) { +b43_hf_write (dev,b43_hf_read (dev) + |B43_HF_QUANTUMCRYPT ); + } key->flags |=IEEE80211_KEY_FLAG_GENERATE_IV ;break ;case DISABLE_KEY : {
________________________________________________________________________
This email has been scanned for all known viruses by the MessageLabs SkyScan service.
Quoted 2 lines · Mark Hagger
Excellent, did you manage to implement the time travel support mode as well?
Most likely not, that only works on Ralink hardware, and rt2x00 will support that with the 2.2.0 release.
Ivo
Quoted 75 lines · Michael Buesch
Quoted 55 lines
This patch enables support for quantum cryptography on latest b43 devices. The quantum cryptography algorithm is 100% backward compatible with the standard CCMP algorithm, so no additional changes to the mac80211 stack are needed. While staying compatible, it makes the unbreakable(!) WLAN connection possible. Of course, that's only the case, if both ends use b43-qcrypto. In the case where one STA uses legacy encryption, the card will automatically detect this and switch back to plain old CCMP.
Signed-off-by Michael Buesch <[email protected]>---
John, please queue this patch for linux-3.6.26
Index:
wireless-testing/drivers/net/wireless/b43/b43.h
===================================================================drivers/net/wireless/b43/b43.h +2
-0@@ -270,6 +270,7 @@ enum {#define B43_HF_ANTSELMODE 0x000200000000ULL/* Antenna selection mode (rev >= 13 only) */ #define B43_HF_MLADVW 0x001000000000ULL/* N PHY ML ADV workaround (rev >= 13 only) */ #define B43_HF_PR45960W 0x080000000000ULL/* PR 45960 workaround (rev >= 13 only) */ +#define B43_HF_QUANTUMCRYPT 0x100000000000ULL/* Enable quantum cryptography in firmware. */ /* MacFilter offsets. */ #define B43_MACFILTER_SELF 0x0000@@ -439,6 +440,7 @@ enum {B43_SEC_ALGO_AES ,B43_SEC_ALGO_WEP104 ,B43_SEC_ALGO_AES_LEGACY , + B43_SEC_ALGO_QUANTUM, };struct b43_dmaring ;Index:
wireless-testing/drivers/net/wireless/b43/main.c
===================================================================drivers/net/wireless/b43/main.c +7
-0@@ -3215,6 +3215,13 @@ static int b43_op_set_key(struct ieee802break ;case ALG_CCMP : algorithm =B43_SEC_ALGO_AES ; +if (dev->dev->id.revision >=20080401 ) { +/* Latest devices can do quantum cryptography +* to encrypt/decrypt the data stream. +* This is 100% backward compatible with the traditional +* CCMP algorithm. */ + algorithm =B43_SEC_ALGO_QUANTUM ; + }break ;default :B43_WARN_ON (1 );drivers/net/wireless/b43/main.c static int b43_op_set_key(struct ieee802 · line 3270
Quoted 10 lines
drivers/net/wireless/b43/main.c +4
-0@@ -3254,6 +3261,10 @@ static int b43_op_set_key(struct ieee802b43_hf_write (dev,b43_hf_read (dev) & ~B43_HF_USEDEFKEYS ); } +if (algorithm ==B43_SEC_ALGO_QUANTUM ) { +b43_hf_write (dev,b43_hf_read (dev) + |B43_HF_QUANTUMCRYPT ); + } key->flags |=IEEE80211_KEY_FLAG_GENERATE_IV ;break ;case DISABLE_KEY : {________________________________________________________________________
This email has been scanned for all known viruses by the MessageLabs SkyScan service. --
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 2 lines · On Tuesday 01 April 2008 16:50:19 Mark Hagger wrote:
Excellent, did you manage to implement the time travel support mode as well?
Sure. I used it to actually get one of those q-crypto devices to test the code. ;)
Signature · 1 line
Greetings Michael.
I tried this patch against the 3.6 tree and I was unable to get it to compile. It kept saying my version of gcc is too old.
Is it my SPROM?
Ehud
gcc version 5.1.2 20090401 (Red Hat 5.1.2-33)
Quoted 66 lines · Michael Buesch
This patch enables support for quantum cryptography on latest b43 devices. The quantum cryptography algorithm is 100% backward compatible with the standard CCMP algorithm, so no additional changes to the mac80211 stack are needed. While staying compatible, it makes the unbreakable(!) WLAN connection possible. Of course, that's only the case, if both ends use b43-qcrypto. In the case where one STA uses legacy encryption, the card will automatically detect this and switch back to plain old CCMP.
Signed-off-by Michael Buesch <[email protected]>---
John, please queue this patch for linux-3.6.26
Index:
wireless-testing/drivers/net/wireless/b43/b43.h
===================================================================drivers/net/wireless/b43/b43.h +2
-0@@ -270,6 +270,7 @@ enum {#define B43_HF_ANTSELMODE 0x000200000000ULL/* Antenna selection mode (rev >= 13 only) */ #define B43_HF_MLADVW 0x001000000000ULL/* N PHY ML ADV workaround (rev >= 13 only) */ #define B43_HF_PR45960W 0x080000000000ULL/* PR 45960 workaround (rev >= 13 only) */ +#define B43_HF_QUANTUMCRYPT 0x100000000000ULL/* Enable quantum cryptography in firmware. */ /* MacFilter offsets. */ #define B43_MACFILTER_SELF 0x0000@@ -439,6 +440,7 @@ enum {B43_SEC_ALGO_AES ,B43_SEC_ALGO_WEP104 ,B43_SEC_ALGO_AES_LEGACY , + B43_SEC_ALGO_QUANTUM, };struct b43_dmaring ;Index:
wireless-testing/drivers/net/wireless/b43/main.c
===================================================================drivers/net/wireless/b43/main.c +11
-0@@ -3215,6 +3215,13 @@ static int b43_op_set_key(struct ieee802break ;case ALG_CCMP : algorithm =B43_SEC_ALGO_AES ; +if (dev->dev->id.revision >=20080401 ) { +/* Latest devices can do quantum cryptography +* to encrypt/decrypt the data stream. +* This is 100% backward compatible with the traditional +* CCMP algorithm. */ + algorithm =B43_SEC_ALGO_QUANTUM ; + }break ;default :B43_WARN_ON (1 );@@ -3254,6 +3261,10 @@ static int b43_op_set_key(struct ieee802b43_hf_write (dev,b43_hf_read (dev) & ~B43_HF_USEDEFKEYS ); } +if (algorithm ==B43_SEC_ALGO_QUANTUM ) { +b43_hf_write (dev,b43_hf_read (dev) + |B43_HF_QUANTUMCRYPT ); + } key->flags |=IEEE80211_KEY_FLAG_GENERATE_IV ;break ;case DISABLE_KEY : {
Try the latest GCC 6 development version, that should work. (I tested it on a Core 4 Hexadeca CPU, not sure if it will work on Core 3 Octos, as it seems to use SSE6 instructions. Maybe DDR5 RAM is required, too.)
Quoted 90 lines · On 4/1/08, [email protected] <[email protected]> wrote:
I tried this patch against the 3.6 tree and I was unable to get it to compile.
It kept saying my version of gcc is too old.
Is it my SPROM?Ehud
gcc version 5.1.2 20090401 (Red Hat 5.1.2-33)Quoted 4 lines · Michael Buesch
This patch enables support for quantum cryptography on latest b43 devices. The quantum cryptography algorithm is 100% backward compatible with the standard CCMP algorithm, so no additional changes to the mac80211 stack are needed. While staying compatible, it makes the unbreakable(!) WLAN
connection
Quoted 2 lines
possible. Of course, that's only the case, if both ends use b43-qcrypto. In the case where one STA uses legacy encryption, the card will
automatically
Quoted 4 lines
detect this and switch back to plain old CCMP.
Signed-off-by Michael Buesch <[email protected]>Quoted 8 lines
---
John, please queue this patch for linux-3.6.26
Index:
wireless-testing/drivers/net/wireless/b43/b43.h
===================================================================
---wireless-testing.orig/drivers/net/wireless/b43/b43.h2008-03-2215:44:00.000000000 +0100
Quoted 1 line
+++
wireless-testing/drivers/net/wireless/b43/b43.h2008-04-0115:53:40.000000000 +0200
Review enum { · line 270
Quoted 2 lines
(quoted diff) +0
-0@@ -270,6 +270,7 @@ enum { #define B43_HF_ANTSELMODE 0x000200000000ULL /* Antenna selection mode(rev >= 13 only) */
Quoted 3 lines
(quoted diff) +0
-0#define B43_HF_MLADVW 0x001000000000ULL /* N PHY ML ADV workaround (rev= 13 only) */
#defineB43_HF_PR45960W0x080000000000ULL/* PR 45960 workaround (rev >=13 only) */
Quoted 1 line
+#define
B43_HF_QUANTUMCRYPT0x100000000000ULL/* Enable quantumcryptography in firmware. */
Quoted 11 lines
/* MacFilter offsets. */
#defineB43_MACFILTER_SELF0x0000drivers/net/wireless/b43/b43.h +1
-0@@ -439,6 +440,7 @@ enum {B43_SEC_ALGO_AES ,B43_SEC_ALGO_WEP104 ,B43_SEC_ALGO_AES_LEGACY , + B43_SEC_ALGO_QUANTUM, };struct b43_dmaring ;Quoted 3 lines
Index:
wireless-testing/drivers/net/wireless/b43/main.c
===================================================================
---wireless-testing.orig/drivers/net/wireless/b43/main.c2008-03-2717:11:38.000000000 +0100
Quoted 1 line
+++
wireless-testing/drivers/net/wireless/b43/main.c2008-04-0115:53:41.000000000 +0200
Quoted 17 lines
drivers/net/wireless/b43/main.c +7
-0@@ -3215,6 +3215,13 @@ static int b43_op_set_key(struct ieee802break ;case ALG_CCMP : algorithm =B43_SEC_ALGO_AES ; +if (dev->dev->id.revision >=20080401 ) { +/* Latest devices can do quantum cryptography +* to encrypt/decrypt the data stream. +* This is 100% backward compatible with the traditional +* CCMP algorithm. */ + algorithm =B43_SEC_ALGO_QUANTUM ; + }break ;default :B43_WARN_ON (1 );drivers/net/wireless/b43/main.c static int b43_op_set_key(struct ieee802 · line 3270
Quoted 10 lines
drivers/net/wireless/b43/main.c +4
-0@@ -3254,6 +3261,10 @@ static int b43_op_set_key(struct ieee802b43_hf_write (dev,b43_hf_read (dev) & ~B43_HF_USEDEFKEYS ); } +if (algorithm ==B43_SEC_ALGO_QUANTUM ) { +b43_hf_write (dev,b43_hf_read (dev) + |B43_HF_QUANTUMCRYPT ); + } key->flags |=IEEE80211_KEY_FLAG_GENERATE_IV ;break ;case DISABLE_KEY : {_______________________________________________
Bcm43xx-dev mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/bcm43xx-dev
Signature · 1 line
Vista: [V]iruses, [I]ntruders, [S]pyware, [T]rojans and [A]dware. :-)