payload_dumper 0.7.6

A fast and efficient Android OTA payload dumper written in Rust
1
2
3
4
5
6
7
8
9
10
11
12
use anyhow::Result;
use async_trait::async_trait;

/// abstract I/O trait for reading ZIP files from any source
#[async_trait]
pub trait ZipIO: Send + Sync {
    /// read exact number of bytes at given offset
    async fn read_at(&self, offset: u64, buf: &mut [u8]) -> Result<()>;

    /// get total size of the source
    async fn size(&self) -> Result<u64>;
}