MCPcopy Create free account
hub / github.com/NodeDB-Lab/nodedb / write_ciphertext_blob

Method write_ciphertext_blob

nodedb/src/control/security/keystore/vault.rs:90–99  ·  view source on GitHub ↗
(&self, ciphertext: &str)

Source from the content-addressed store, hash-verified

88 }
89
90 fn write_ciphertext_blob(&self, ciphertext: &str) -> Result<()> {
91 std::fs::write(&self.ciphertext_blob_path, ciphertext).map_err(|e| {
92 crate::Error::Encryption {
93 detail: format!(
94 "failed to write Vault ciphertext blob to {}: {e}",
95 self.ciphertext_blob_path.display()
96 ),
97 }
98 })
99 }
100
101 async fn decrypt_with_vault(&self, ciphertext: &str) -> Result<Zeroizing<[u8; 32]>> {
102 let token = self.read_token()?;

Callers 1

rotateMethod · 0.45

Calls 1

writeFunction · 0.50

Tested by

no test coverage detected