iwd.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 01/10] wiphy: add wiphy_get_supported_ciphers
@ 2022-11-02 20:53 James Prestwood
  2022-11-02 20:53 ` [PATCH v2 02/10] ie: add group/pairwise lists of supported ciphers James Prestwood
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: James Prestwood @ 2022-11-02 20:53 UTC (permalink / raw)
  To: iwd; +Cc: James Prestwood

Similar to wiphy_select_cipher but returns all supported ciphers
included in the mask rather than just one.
---
 src/wiphy.c | 5 +++++
 src/wiphy.h | 2 ++
 2 files changed, 7 insertions(+)

diff --git a/src/wiphy.c b/src/wiphy.c
index bb83f814..10514572 100644
--- a/src/wiphy.c
+++ b/src/wiphy.c
@@ -180,6 +180,11 @@ enum ie_rsn_cipher_suite wiphy_select_cipher(struct wiphy *wiphy, uint16_t mask)
 	return 0;
 }
 
+uint16_t wiphy_get_supported_ciphers(struct wiphy *wiphy, uint16_t mask)
+{
+	return wiphy->supported_ciphers & mask;
+}
+
 static bool wiphy_can_connect_sae(struct wiphy *wiphy)
 {
 	/*
diff --git a/src/wiphy.h b/src/wiphy.h
index 2c6bf86b..f8de7e0e 100644
--- a/src/wiphy.h
+++ b/src/wiphy.h
@@ -68,6 +68,8 @@ typedef void (*wiphy_destroy_func_t)(void *user_data);
 
 enum ie_rsn_cipher_suite wiphy_select_cipher(struct wiphy *wiphy,
 							uint16_t mask);
+uint16_t wiphy_get_supported_ciphers(struct wiphy *wiphy, uint16_t mask);
+
 enum ie_rsn_akm_suite wiphy_select_akm(struct wiphy *wiphy,
 					const struct scan_bss *bss,
 					enum security security,
-- 
2.34.3


^ permalink raw reply related	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2022-11-02 20:53 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-02 20:53 [PATCH v2 01/10] wiphy: add wiphy_get_supported_ciphers James Prestwood
2022-11-02 20:53 ` [PATCH v2 02/10] ie: add group/pairwise lists of supported ciphers James Prestwood
2022-11-02 20:53 ` [PATCH v2 03/10] ap: add profile settings PairwiseCiphers/GroupCipher James Prestwood
2022-11-02 20:53 ` [PATCH v2 04/10] p2p: limit ciphers to CCMP/TKIP James Prestwood
2022-11-02 20:53 ` [PATCH v2 05/10] doc: document PairwiseCiphers/GroupCiphers AP settings James Prestwood
2022-11-02 20:53 ` [PATCH v2 06/10] ap: add PairwiseCiphers/GroupCipher to dbus interface James Prestwood
2022-11-02 20:53 ` [PATCH v2 07/10] client: add ap support for PairwiseCiphers/GroupCipher James Prestwood
2022-11-02 20:53 ` [PATCH v2 08/10] auto-t: add proper AccessPoint object class James Prestwood
2022-11-02 20:53 ` [PATCH v2 09/10] auto-t: test AP fails to start with unsupported ciphers James Prestwood
2022-11-02 20:53 ` [PATCH v2 10/10] auto-t: add AP test for all pairwise/group cipher combos James Prestwood

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).