[YMCS/YDMP Free Trial Program]Yealink would like to offer Free Trial Program of Yealink device management service for our current eligible customers. You can see the details below.
https://www.yealink.com/ydmp-freetrial-2020


Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
AES Encryption
Author Message
damo@launtel.net.au Offline
Damian Ivereigh
**

Posts: 6
Joined: Jan 2015
Reputation: 0
Post: #13
RE: AES Encryption
Here is the same algorithm written in perl. Key supplied as argument (must be 16 characters) and config file fed into stdin, encrypted file is printed to stdout.

Code:
#!/usr/bin/perl -w
use Crypt::Mode::ECB;

my $key = $ARGV[0]; # length has to be 16 characters
my $plaintext = do { local $/; <STDIN> };
# Pad to a multiple of 16 (128 bits) with spaces
my $pad=(16-(length($plaintext) % 16)) % 16;
for (my $n=0; $n<$pad; $n++) {
        $plaintext .= ' ';
}
my $c = Crypt::Mode::ECB->new('AES', 0);
print($c->encrypt($plaintext, $key));
04-05-2015 07:27 AM
Find all posts by this user    like0    dislike0 Quote this message in a reply
Post Reply 


Messages In This Thread
AES Encryption - ldardini - 12-05-2012, 06:14 AM
RE: AES Encryption - Flora_Yealink - 12-05-2012, 06:54 PM
RE: AES Encryption - ldardini - 12-06-2012, 12:45 AM
RE: AES Encryption - Yealink Support - 12-26-2012, 08:49 AM
RE: AES Encryption - ldardini - 12-26-2012, 04:45 PM
RE: AES Encryption - Yealink Support - 12-26-2012, 06:04 PM
RE: AES Encryption - sanjay-intuit - 02-17-2013, 06:38 PM
RE: AES Encryption - Yealink Support - 06-13-2013, 03:39 PM
RE: AES Encryption - jessicasmith - 08-12-2013, 06:29 PM
RE: AES Encryption - ldardini - 08-12-2013, 09:01 PM
RE: AES Encryption - bOOster - 09-18-2013, 04:54 PM
RE: AES Encryption - bOOster - 09-20-2013, 11:45 PM
RE: AES Encryption - damo@launtel.net.au - 04-05-2015 07:27 AM

Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  AES Encryption from Python jvanveen 1 5,070 02-04-2015 04:17 PM
Last Post: jvanveen

Forum Jump:


User(s) browsing this thread: 1 Guest(s)

Contact Us   Yealink   Return to Top   Return to Content   Lite (Archive) Mode   RSS Syndication