sqep 0.1.0

SQEP – Secure Quantum Encryption Protocol powered by ContiCrypt
Documentation
#[cfg(not(feature = "plus"))]
use sqep::ZeroshieldCipher;

#[cfg(feature = "plus")]
use sqep::SQEPPlus;

fn main() {
    #[cfg(not(feature = "plus"))]
    {
        let cipher = ZeroshieldCipher::new();
        let data = b"hello quantum world!";
        let (encrypted, meta) = cipher.encrypt_with_meta(data);
        println!("Encrypted bytes: {:?}", encrypted);
        println!("Meta: {:?}", meta);

        let decrypted = cipher.decrypt(&encrypted).expect("Decryption failed");
        println!("Decrypted: {:?}", String::from_utf8_lossy(&decrypted));
    }

    #[cfg(feature = "plus")]
    {
        let cipher = SQEPPlus::new();
        let data = b"hello quantum world!";
        let (encrypted, meta) = cipher.encrypt_plus(data);
        println!("Encrypted bytes: {:?}", encrypted);
        println!("Meta: {:?}", meta);

        let decrypted = cipher.decrypt_plus(&encrypted).expect("Decryption failed");
        println!("Decrypted: {:?}", String::from_utf8_lossy(&decrypted));
    }
}