Skip to content

Commit 1170b31

Browse files
committed
BLE: Remove useless pal sm API
1 parent e29ea95 commit 1170b31

File tree

3 files changed

+0
-73
lines changed

3 files changed

+0
-73
lines changed

features/FEATURE_BLE/ble/pal/PalSecurityManager.h

Lines changed: 0 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -792,22 +792,6 @@ class SecurityManager : private mbed::NonCopyable<SecurityManager> {
792792
bool mitm
793793
) = 0;
794794

795-
virtual ble_error_t disable_encryption(
796-
connection_handle_t connection
797-
) = 0;
798-
799-
/**
800-
* Get the link's key size.
801-
*
802-
* @param[in] connection connection handle
803-
* @param[out] bytesize size of the encryption key in bytes
804-
* @retval BLE_ERROR_NONE On success, else an error code indicating reason for failure
805-
*/
806-
virtual ble_error_t get_encryption_key_size(
807-
connection_handle_t connection,
808-
uint8_t &bytesize
809-
) = 0;
810-
811795
/**
812796
* Encrypt data with a given key. This uses the facility on the controller to
813797
* perform the encryption.
@@ -891,17 +875,6 @@ class SecurityManager : private mbed::NonCopyable<SecurityManager> {
891875
// Authentication
892876
//
893877

894-
/**
895-
* Request authentication of the connection. This will trigger an appropriate reaction,
896-
* which might include encryption or pairing/re-pairing.
897-
*
898-
* @param[in] connection connection handle
899-
* @retval BLE_ERROR_NONE On success, else an error code indicating reason for failure
900-
*/
901-
virtual ble_error_t request_authentication(
902-
connection_handle_t connection
903-
) = 0;
904-
905878
/**
906879
* Generate and return 8 octets of random data compliant with [FIPS PUB 140-2]
907880
*

features/FEATURE_BLE/targets/TARGET_CORDIO/CordioPalSecurityManager.h

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -147,25 +147,6 @@ class CordioSecurityManager : public ::ble::pal::SecurityManager {
147147
bool mitm
148148
);
149149

150-
/**
151-
* @see ::ble::pal::SecurityManager::disable_encryption
152-
*/
153-
virtual ble_error_t disable_encryption(connection_handle_t connection);
154-
155-
/**
156-
* @see ::ble::pal::SecurityManager::get_encryption_status
157-
*/
158-
virtual ble_error_t get_encryption_status(
159-
connection_handle_t connection, LinkSecurityStatus_t &status
160-
);
161-
162-
/**
163-
* @see ::ble::pal::SecurityManager::get_encryption_key_size
164-
*/
165-
virtual ble_error_t get_encryption_key_size(
166-
connection_handle_t, uint8_t &bitsize
167-
);
168-
169150
/**
170151
* @see ::ble::pal::SecurityManager::encrypt_data
171152
*/
@@ -274,11 +255,6 @@ class CordioSecurityManager : public ::ble::pal::SecurityManager {
274255
connection_handle_t connection, pairing_failure_t reason
275256
);
276257

277-
/**
278-
* @see ::ble::pal::SecurityManager::request_authentication
279-
*/
280-
virtual ble_error_t request_authentication(connection_handle_t connection);
281-
282258
/**
283259
* @see ::ble::pal::SecurityManager::get_random_data
284260
*/

features/FEATURE_BLE/targets/TARGET_CORDIO/source/CordioPalSecurityManager.cpp

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -171,23 +171,6 @@ ble_error_t CordioSecurityManager::enable_encryption(
171171
return BLE_ERROR_NONE;
172172
}
173173

174-
ble_error_t CordioSecurityManager::disable_encryption(connection_handle_t connection)
175-
{
176-
return BLE_ERROR_NOT_IMPLEMENTED;
177-
}
178-
179-
ble_error_t CordioSecurityManager::get_encryption_status(
180-
connection_handle_t connection, LinkSecurityStatus_t &status
181-
) {
182-
return BLE_ERROR_NOT_IMPLEMENTED;
183-
}
184-
185-
ble_error_t CordioSecurityManager::get_encryption_key_size(
186-
connection_handle_t, uint8_t &bitsize
187-
) {
188-
return BLE_ERROR_NOT_IMPLEMENTED;
189-
}
190-
191174
ble_error_t CordioSecurityManager::encrypt_data(
192175
const byte_array_t<16> &key,
193176
encryption_block_t &data
@@ -342,11 +325,6 @@ ble_error_t CordioSecurityManager::cancel_pairing(
342325
return BLE_ERROR_NONE;
343326
}
344327

345-
ble_error_t CordioSecurityManager::request_authentication(connection_handle_t connection)
346-
{
347-
return BLE_ERROR_NOT_IMPLEMENTED;
348-
}
349-
350328
ble_error_t CordioSecurityManager::get_random_data(byte_array_t<8> &random_data)
351329
{
352330
SecRand(random_data.buffer(), random_data.size());

0 commit comments

Comments
 (0)