Encryption Speed: symmetric vs asymmetric

I’m doing some clean-up on my computer and before I delete this, I thought I’d do a quick post on it. It’s been said that asymmetric encryption should be used for key-exchange (a la Diffie-Helman) because it’s too slow to do regular encryption.

Well, for a project I was working on, I did some simple time-trials to test this, and below is what I discovered.

image

image

And if you are interested in the raw data, here is it – below:

 Bytes 

AES Time

PKI Time

500,000 0.013339 0.384184
1,000,000 0.027213 0.770122
1,500,000 0.040376 1.173847
2,000,000 0.052063 1.548068
2,500,000 0.06758 1.938064
3,000,000 0.077545 2.321055
3,500,000 0.090704 2.719512
4,000,000 0.11909 3.073616
4,500,000 0.113535 3.463312
5,000,000 0.141236 3.864439
5,500,000 0.14997 4.260612
6,000,000 0.149839 4.656699
6,500,000 0.163659 5.034873
7,000,000 0.214086 5.434759
7,500,000 0.200605 5.857154
8,000,000 0.201672 6.19732
8,500,000 0.225572 6.547349
9,000,000 0.280918 6.936493
9,500,000 0.261376 7.321592
10,000,000 0.25104 7.697328
10,500,000 0.260751 8.098898
11,000,000 0.334143 8.57437
11,500,000 0.307117 8.929148

The first column is how many bytes I was trying to encrypt, the middle column is how long it too using AES-256, and the 3rd column is how long it took using an x.509 certificate.

Posted in General, Security, Uncategorized
One comment on “Encryption Speed: symmetric vs asymmetric
  1. […] By the way, this more-secure PKI is only used to exchange a key because AES-256 encryption is is 4x to 29x faster than PKI! […]

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Archives
Categories

Enter your email address to follow this blog and receive notifications of new posts by email.

Join 5 other followers

%d bloggers like this: