I m new in this world of Cryptography. I`m trying to check the performance of the various algorithms on with OpenSSL.

Looking on the internet I find this command :

openssl speed aes-128-cbc des md5

that gives me this result:

```
type 16 bytes 64 bytes 256 bytes 1024 bytes 8192 bytes 16384 bytes
md5 141163.54k 328300.37k 585034.84k 725997.91k 781058.05k 784356.69k
des cbc 87455.53k 88825.00k 90427.39k 90697.05k 89822.55k 89953.62k
des ede3 34051.47k 34361.83k 34424.58k 34591.40k 34493.78k 34635.78k
aes-128 cbc 274253.87k 296425.66k 298769.49k 304985.43k 301938.01k 302945.62k
```

So the question is:
*If I wish to measure the time with a specific algorithm, with a specific file...how can I do?*

Ex. I have a `picture.jpg`

that I what encrypt with AES-128. I wish to know how many time the PC compute this encryption procedure.

`time`

but it is not perfect – kelalaka Oct 29 '19 at 11:39`time`

with the encryption command. The encryption procedure generally runs just once per block, which for AES is 16 bytes. MD5 is not encryption. – Maarten Bodewes Oct 29 '19 at 12:17manytimes" the block cipher (e.g. AES-128) is used: that's a function of file size and block size, and was (mildly) approriate in crypto.SE where the question used to be. If you want to know "howmuchtime" is spent in the encryption procedure, well that's a benchmarking problem, and as a rule of thumb for a proper implementation of a modern cipher (esp. AES-128 on a modern CPU with AES-NI), that's not much compared to the time spent in file IO. – fgrieu Oct 29 '19 at 12:17