@@ -1,3 +1,4 @@
+// SPDX-License-Identifier: AGPL-3.0-or-later
pub mod local_fs;
pub mod mode_authorizer;
use crate::root_creds;
use super::node_creds;
use btfproto::local_fs::AuthzContext;
use crate::{msg::*, Handle, Inode};
use btlib::{bterr, Result};
#![feature(type_alias_impl_trait)]
pub type Inode = btlib::Inode;
use crate::{msg::*, server::FsProvider};
use btlib::{
use super::{Handle, Inode};
use crate::{
msg::{Read as ReadMsg, *},
Handle, Inode,
use super::DEFAULT_CONFIG;
use std::{
net::IpAddr,
mod config;
use btfproto::{
use std::path::{Path, PathBuf};
use crate::{fuse_fs::FuseFs, PathExt, DEFAULT_CONFIG};
use btfproto::server::FsProvider;
use btfproto::{msg::*, server::FsProvider};
bterr, collections::Bijection, error::DisplayErr, AuthzAttrs, BlockId, BlockMetaSecrets,
mod fuse_daemon;
use fuse_daemon::FuseDaemon;
@@ -1,2 +1,3 @@
mod tpm_cred_store_harness;
pub use tpm_cred_store_harness::TpmCredStoreHarness;
//! Module containing [TpmCredStoreHarness].
//! Benchmarks for implementations of the [Block] trait.
//! You can run these with `cargo bench`.
use positioned_io::{ReadAt, Size, WriteAt};
use std::io::{self, Read, Seek, SeekFrom, Write};
crypto::{BtHasher, HashKind},
Principal, Result,
use log::error;
use positioned_io::Size;
use std::io::{self, Cursor, Read, Seek, SeekFrom};
//! A collection of collection types.
pub mod hash_map_with_default;
//! This module contains the [Bijection] type.
use super::HashMapWithDefault;
//! This module defines [HashMapWithDefault], which is a newtype wrapping a [HashMap] which allows
//! a default value to be defined.
//! When a key is not found in the [HashMap] the default value is returned, instead of [None].
//! This module contains functions which are useful for configuring applications.
use std::env::VarError;
pub mod tpm;
pub mod merkle_stream;
pub use private::{
MerkleNode, MerkleStream, MerkleTree, MerkleTreeKind, Sha2_256Node, VariantMerkleTree,
VecMerkleTree,
pub use private::SignStream;
mod private {
use crate::error::{DisplayErr, StringError};
use super::*;
//! Code for converting [Writecap]s to and from the X.509 certificate format.
//! TODO: Improve the efficiency and quality of this code by moving to a different library for
//! handling X.509 certificates.
//! This module defines the `Error` and `Result` types used in this crate. It also defines macros,
//! `bterr!` and `btensure!`. The first accepts either a type which is
//! `StdError + Send + Sync + 'static` or the same arguments as `format!`, allowing you to create
pub mod accessor;
mod block_path;
pub mod buf_reader;
use chrono;
use env_logger;
use std::io::Write;
use safemem::write_bytes;
/// Tests which ensure that the main data structures can be round-tripped faithfully.
use btserde::{from_vec, to_vec, Error, Result};
/// Test data and functions to help with testing.
use btserde::{Error, Result};
use fuse_backend_rs::{
pub use private::Trailered;
use btlib::{error::BoxInIoErr, Result};
use btserde::{from_slice, read_from};
use bytes::BytesMut;
//! Code which enables sending messages between processes in the blocktree system.
//! This module is for types which contribute to the configuration of TLS.
use crate::Result;
use btmsg::*;
error::{Error, Result},
reader::{ReadAdapter, Reader, SliceAdapter},
use super::{from_vec, to_vec, Result};
use serde::{Deserialize, Serialize};
use serde_big_array::BigArray;
use serde::{de, ser};
fmt::{self, Display},
//! This crate defines a compact binary serialization format for use in the Block Tree system.
mod de;
//! This module contains the [Reader] trait which enables zero-copy deserialization over
//! different input types.
use crate::{error::MapError, Error, Result};
use serde::{
ser::{
self, SerializeMap, SerializeSeq, SerializeStruct, SerializeStructVariant, SerializeTuple,
use anyhow::anyhow;
use nix::{