-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Change persistent storage SyncGetKeyValue API to match constraints of…
… KvsStorageManager (#20164) * PersistentStorageDelegate::SyncGetKeyValue remove ability to get value size Some implmentation of PersistentStorageDelegate use KeyValueStoreManager which is not capable of giving the size of for the time being, which makes this obligation impossible to fulfill right now. After performing a code audit no one is currently using the functionality to get the size, so this change is safe, but we need platforms to adhear to the this updated description. We also are now enforcing the PersistentStorageDelegate::SyncGetKeyValue API such that we fill up the buffer up to the size provided even if the buffer is not large enough. This is done so that in the case a version downgrade needs to happen that (due to OTA revert, security reason, or any other reason) we can make sure as long as TLV data was stored you could still ensure that you are able to work in critical situations. * Update implemenations of PersistentStorageDelegate::SyncGetKeyValue * Restyle * Restyle * Fix a couple things * Address comments from PR * Restyle * Fix CI issue * Address PR comments * Update src/lib/core/CHIPPersistentStorageDelegate.h Co-authored-by: Tennessee Carmel-Veilleux <[email protected]> * Address PR comments, add audit test * Restyle * Address PR comments * Add test for base64 symbol in key and value * Apply suggestions from code review Co-authored-by: Boris Zbarsky <[email protected]> * Address when buffer is nulptr and size is 0 * Fix comment from PR * Restyle * add include Co-authored-by: Tennessee Carmel-Veilleux <[email protected]> Co-authored-by: Boris Zbarsky <[email protected]>
- Loading branch information
Showing
8 changed files
with
492 additions
and
98 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.