55 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
66 *
77 * Copyright (C) 2016 Jonathan Naylor, G4KLX
8- * Copyright (C) 2017-2022,2024 Bryan Biedenkapp, N2PLL
8+ * Copyright (C) 2017-2022,2024,2025 Bryan Biedenkapp, N2PLL
99 * Copyright (c) 2024 Patrick McDonnell, W3AXL
1010 * Copyright (c) 2024 Caleb, KO4UYJ
1111 *
@@ -50,6 +50,7 @@ namespace lookups
5050 m_peerAlias (),
5151 m_peerPassword (),
5252 m_peerLink (false ),
53+ m_canRequestKeys (false ),
5354 m_peerDefault (false )
5455 {
5556 /* stub */
@@ -60,13 +61,16 @@ namespace lookups
6061 * @param peerAlias Peer alias
6162 * @param peerPassword Per Peer Password.
6263 * @param sendConfiguration Flag indicating this peer participates in peer link and should be sent configuration.
64+ * @param peerLink lag indicating if the peer participates in peer link and should be sent configuration.
65+ * @param canRequestKeys Flag indicating if the peer can request encryption keys.
6366 * @param peerDefault Flag indicating this is a "default" (i.e. undefined) peer.
6467 */
65- PeerId (uint32_t peerId, const std::string& peerAlias, const std::string& peerPassword, bool peerLink, bool peerDefault) :
68+ PeerId (uint32_t peerId, const std::string& peerAlias, const std::string& peerPassword, bool peerLink, bool canRequestKeys, bool peerDefault) :
6669 m_peerId (peerId),
6770 m_peerAlias (peerAlias),
6871 m_peerPassword (peerPassword),
6972 m_peerLink (peerLink),
73+ m_canRequestKeys (canRequestKeys),
7074 m_peerDefault (peerDefault)
7175 {
7276 /* stub */
@@ -83,6 +87,7 @@ namespace lookups
8387 m_peerAlias = data.m_peerAlias ;
8488 m_peerPassword = data.m_peerPassword ;
8589 m_peerLink = data.m_peerLink ;
90+ m_canRequestKeys = data.m_canRequestKeys ;
8691 m_peerDefault = data.m_peerDefault ;
8792 }
8893
@@ -95,14 +100,17 @@ namespace lookups
95100 * @param peerAlias Peer Alias
96101 * @param peerPassword Per Peer Password.
97102 * @param sendConfiguration Flag indicating this peer participates in peer link and should be sent configuration.
103+ * @param peerLink lag indicating if the peer participates in peer link and should be sent configuration.
104+ * @param canRequestKeys Flag indicating if the peer can request encryption keys.
98105 * @param peerDefault Flag indicating this is a "default" (i.e. undefined) peer.
99106 */
100- void set (uint32_t peerId, const std::string& peerAlias, const std::string& peerPassword, bool peerLink, bool peerDefault)
107+ void set (uint32_t peerId, const std::string& peerAlias, const std::string& peerPassword, bool peerLink, bool canRequestKeys, bool peerDefault)
101108 {
102109 m_peerId = peerId;
103110 m_peerAlias = peerAlias;
104111 m_peerPassword = peerPassword;
105112 m_peerLink = peerLink;
113+ m_canRequestKeys = canRequestKeys;
106114 m_peerDefault = peerDefault;
107115 }
108116
@@ -123,6 +131,10 @@ namespace lookups
123131 * @brief Flag indicating if the peer participates in peer link and should be sent configuration.
124132 */
125133 __PROPERTY_PLAIN (bool , peerLink);
134+ /* *
135+ * @brief Flag indicating if the peer can request encryption keys.
136+ */
137+ __PROPERTY_PLAIN (bool , canRequestKeys);
126138 /* *
127139 * @brief Flag indicating if the peer is default.
128140 */
@@ -166,8 +178,9 @@ namespace lookups
166178 * @param peerId Unique peer ID to add.
167179 * @param password Per Peer Password.
168180 * @param peerLink Flag indicating this peer will participate in peer link and should be sent configuration.
181+ * @param canRequestKeys Flag indicating if the peer can request encryption keys.
169182 */
170- void addEntry (uint32_t id, const std::string& alias = " " , const std::string& password = " " , bool peerLink = false );
183+ void addEntry (uint32_t id, const std::string& alias = " " , const std::string& password = " " , bool peerLink = false , bool canRequestKeys = false );
171184 /* *
172185 * @brief Removes an existing entry from the list.
173186 * @param peerId Unique peer ID to remove.
0 commit comments