Net::SS...chaPoly(3)

πŸ“¦
version 2.144 Β· 4 versions
, in fedora 44

πŸ’– Net::SS...chaPoly(3) β€” bestie edition πŸ’–

okay so this is a User Contributed Perl Documentation page, and the module it's serving is Net::SSH::Perl::Cipher::ChachaPoly. yes the title is abbreviated because terminals are small and life is short. let's get into it 🫢


✨ NAME ✨

Net::SSH::Perl::Cipher::ChachaPoly β€” provides Chacha20 encryption with Poly1305 Authentication support for Net::SSH::Perl. periodt. πŸ’…


πŸ¦‹ SYNOPSIS πŸ¦‹

no cap, here's the whole vibe, verbatim:

use Net::SSH::Perl::Cipher;
my $eight_byte_iv = pack('N',0) . pack('N',1);
my $eight_byte_counter = chr(1) . 7 x "\0"; # little endian

my $cipher = Net::SSH::Perl::Cipher->new('ChachaPoly', $key);

# generate poly key
$cipher->ivsetup($eight_byte_iv,undef);
my $poly_key = "\0" x POLY1305_KEYLEN; # 32 byte key
$poly_key = $ciph->encrypt($poly_key);

$cipher->ivsetup($eight_byte_iv,$eight_byte_counter);
my $enc = $cipher->encrypt($plaintext);
my $tag = $cipher->poly1305($enc,$poly_key);
πŸ‘€ notice $ciph->encrypt in there β€” that's exactly what the original says, so I'm leaving it exactly as-is. copy-paste responsibly, bestie.

🌸 DESCRIPTION 🌸

Net::SSH::Perl::Cipher::Chacha provides Chacha20 encryption with Poly1305 support for Net::SSH::Perl. (yes, the prose says Chacha β€” again, that's what it says, I'm not touching it πŸ”₯)

This module requires Crypt::OpenSSH::ChachaPoly, which is the little wrapper that gives you the OpenSSH Chacha and Poly1305 functions. so like, that dependency is not optional, it's giving mandatory main character energy. ✨


πŸ‘‘ AUTHOR & COPYRIGHTS πŸ‘‘

Lance Kinley E<lkinley@loyaltymethods.com>

Copyright (c) 2015 Loyalty Methods, Inc.


πŸŽ€ LICENSE πŸŽ€

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. iconic behavior tbh 🌈


πŸ’€ POD ERRORS πŸ’€

okay so. not everything was slay. the doc itself had some coding errors, and here's the rundown:

Around line 149:

Unknown E content in E<lkinley@loyaltymethods.com>

like β€” the E<...> formatting thing got fed an email address and it simply could not deal. it's fine. it's fine. 😭


perl v5.42.0 Β· 2026-01-17 β€” that's the source/version and date stamp from the footer, mwah πŸ’œ go forth and encrypt, bestie, you got this πŸ§šβ€β™€οΈπŸ“

πŸ“¦ where this page comes from