Net::SS...chaPoly(3)
π 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
- fedora 44: perl-Net-SSH-Perl 2.144-2.fc44 Β· GPL-1.0-or-later OR Artistic-1.0-Perl
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms