Net::TacacsPlus::Packet::Header - Tacacs+ packet header
3. The TACACS+ packet header
All TACACS+ packets always begin with the following 12 byte header. The header is always cleartext and describes the remainder of the packet:
1 2 3 4 5 6 7 8 1 2 3 4 5 6 7 8 1 2 3 4 5 6 7 8 1 2 3 4 5 6 7 8 +----------------+----------------+----------------+----------------+ |major | minor | | | | |version| version| type | seq_no | flags | +----------------+----------------+----------------+----------------+ | | | session_id | +----------------+----------------+----------------+----------------+ | | | length | +----------------+----------------+----------------+----------------+
Construct tacacs+ packet header object
1. if constructing from parameters:
'version': protocol version 'type': TAC_PLUS_(AUTHEN|AUTHOR|ACCT) 'seq_no': sequencenumber - default 1 'flags': TAC_PLUS_(UNENCRYPTED_FLAG|SINGLE_CONNECT_FLAG) - default none 'session_id': session id
2. if constructing from raw packet
'raw_header': raw packet
Decode $raw_data to version, type, seq_no, flags, session_id, length
returns raw binary representation of header.
NOTE For complete binary header, length of body must be added.
To install Net::TacacsPlus, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Net::TacacsPlus
CPAN shell
perl -MCPAN -e shell install Net::TacacsPlus
For more information on module installation, please visit the detailed CPAN module installation guide.