X-Git-Url: https://git.openssl.org/gitweb/?p=openssl.git;a=blobdiff_plain;f=crypto%2Fperlasm%2Fcbc.pl;h=8aefefb6966c2fa2191264b39290ab67a7c0dc28;hp=24561e759aba6812c1e42a18250aaf606e30b2a7;hb=a5d9549d6ef3a7fdabf1c06ec2d1133be8f4f7bb;hpb=f9c5e5d92e75ccff046774494b9904d849148e5f diff --git a/crypto/perlasm/cbc.pl b/crypto/perlasm/cbc.pl index 24561e759a..8aefefb696 100644 --- a/crypto/perlasm/cbc.pl +++ b/crypto/perlasm/cbc.pl @@ -1,4 +1,11 @@ -#!/usr/local/bin/perl +#! /usr/bin/env perl +# Copyright 1995-2016 The OpenSSL Project Authors. All Rights Reserved. +# +# Licensed under the Apache License 2.0 (the "License"). You may not use +# this file except in compliance with the License. You can obtain a copy +# in the file LICENSE in the source distribution or at +# https://www.openssl.org/source/license.html + # void des_ncbc_encrypt(input, output, length, schedule, ivec, enc) # des_cblock (*input); @@ -8,7 +15,7 @@ # des_cblock (*ivec); # int enc; # -# calls +# calls # des_encrypt((DES_LONG *)tin,schedule,DES_ENCRYPT); # @@ -29,7 +36,7 @@ sub cbc # name is the function name # enc_func and dec_func and the functions to call for encrypt/decrypt # swap is true if byte order needs to be reversed - # iv_off is parameter number for the iv + # iv_off is parameter number for the iv # enc_off is parameter number for the encrypt/decrypt flag # p1,p2,p3 are the offsets for parameters to be passed to the # underlying calls. @@ -107,7 +114,7 @@ sub cbc ############################################################# &set_label("encrypt_loop"); - # encrypt start + # encrypt start # "eax" and "ebx" hold iv (or the last cipher text) &mov("ecx", &DWP(0,$in,"",0)); # load first 4 bytes @@ -201,7 +208,7 @@ sub cbc ############################################################# ############################################################# &set_label("decrypt",1); - # decrypt start + # decrypt start &and($count,0xfffffff8); # The next 2 instructions are only for if the jz is taken &mov("eax", &DWP($data_off+8,"esp","",0)); # get iv[0] @@ -343,7 +350,7 @@ sub cbc &align(64); &function_end_B($name); - + } 1;