aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/libs/openssl/crypto
diff options
context:
space:
mode:
authorheretic <heretic@yandex-team.ru>2022-02-10 16:45:46 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:45:46 +0300
commit81eddc8c0b55990194e112b02d127b87d54164a9 (patch)
tree9142afc54d335ea52910662635b898e79e192e49 /contrib/libs/openssl/crypto
parent397cbe258b9e064f49c4ca575279f02f39fef76e (diff)
downloadydb-81eddc8c0b55990194e112b02d127b87d54164a9.tar.gz
Restoring authorship annotation for <heretic@yandex-team.ru>. Commit 2 of 2.
Diffstat (limited to 'contrib/libs/openssl/crypto')
-rw-r--r--contrib/libs/openssl/crypto/.yandex_meta/licenses.list.txt1936
-rw-r--r--contrib/libs/openssl/crypto/aes/aes_ige.c20
-rw-r--r--contrib/libs/openssl/crypto/armcap.c66
-rw-r--r--contrib/libs/openssl/crypto/asn1/a_object.c18
-rw-r--r--contrib/libs/openssl/crypto/asn1/a_strex.c6
-rw-r--r--contrib/libs/openssl/crypto/asn1/asn1_err.c6
-rw-r--r--contrib/libs/openssl/crypto/asn1/asn1_lib.c24
-rw-r--r--contrib/libs/openssl/crypto/asn1/asn1_par.c4
-rw-r--r--contrib/libs/openssl/crypto/asn1/bio_asn1.c12
-rw-r--r--contrib/libs/openssl/crypto/asn1/bio_ndef.c12
-rw-r--r--contrib/libs/openssl/crypto/asn1/charmap.h2
-rw-r--r--contrib/libs/openssl/crypto/asn1/d2i_pr.c104
-rw-r--r--contrib/libs/openssl/crypto/asn1/t_spki.c4
-rw-r--r--contrib/libs/openssl/crypto/asn1/tasn_dec.c40
-rw-r--r--contrib/libs/openssl/crypto/asn1/tasn_enc.c34
-rw-r--r--contrib/libs/openssl/crypto/asn1/x_algor.c66
-rw-r--r--contrib/libs/openssl/crypto/bio/b_addr.c12
-rw-r--r--contrib/libs/openssl/crypto/bio/b_print.c12
-rw-r--r--contrib/libs/openssl/crypto/bio/b_sock2.c6
-rw-r--r--contrib/libs/openssl/crypto/bio/bss_acpt.c8
-rw-r--r--contrib/libs/openssl/crypto/bio/bss_conn.c56
-rw-r--r--contrib/libs/openssl/crypto/bn/README.pod482
-rw-r--r--contrib/libs/openssl/crypto/bn/bn_div.c10
-rw-r--r--contrib/libs/openssl/crypto/bn/bn_gcd.c406
-rw-r--r--contrib/libs/openssl/crypto/bn/bn_lib.c38
-rw-r--r--contrib/libs/openssl/crypto/bn/bn_mpi.c4
-rw-r--r--contrib/libs/openssl/crypto/bn/bn_prime.h2
-rw-r--r--contrib/libs/openssl/crypto/buildinf-android_arm.h142
-rw-r--r--contrib/libs/openssl/crypto/buildinf-android_arm64.h136
-rw-r--r--contrib/libs/openssl/crypto/buildinf-android_x86.h150
-rw-r--r--contrib/libs/openssl/crypto/buildinf-android_x86_64.h150
-rw-r--r--contrib/libs/openssl/crypto/buildinf-ios-arm.h102
-rw-r--r--contrib/libs/openssl/crypto/buildinf-ios-arm64.h96
-rw-r--r--contrib/libs/openssl/crypto/buildinf-ios-i386.h112
-rw-r--r--contrib/libs/openssl/crypto/buildinf-ios-x86_64.h110
-rw-r--r--contrib/libs/openssl/crypto/buildinf-linux.h2
-rw-r--r--contrib/libs/openssl/crypto/buildinf-linux_aarch64.h52
-rw-r--r--contrib/libs/openssl/crypto/buildinf-osx.h46
-rw-r--r--contrib/libs/openssl/crypto/buildinf-osx_arm64.h74
-rw-r--r--contrib/libs/openssl/crypto/buildinf-win.h46
-rw-r--r--contrib/libs/openssl/crypto/buildinf.h38
-rw-r--r--contrib/libs/openssl/crypto/cmac/cmac.c28
-rw-r--r--contrib/libs/openssl/crypto/cms/cms_lib.c6
-rw-r--r--contrib/libs/openssl/crypto/cms/cms_sd.c8
-rw-r--r--contrib/libs/openssl/crypto/cms/cms_smime.c4
-rw-r--r--contrib/libs/openssl/crypto/conf/conf_def.c34
-rw-r--r--contrib/libs/openssl/crypto/conf/conf_def.h2
-rw-r--r--contrib/libs/openssl/crypto/dh/dh_key.c60
-rw-r--r--contrib/libs/openssl/crypto/dsa/dsa_prn.c18
-rw-r--r--contrib/libs/openssl/crypto/dso/dso_win32.c6
-rw-r--r--contrib/libs/openssl/crypto/ec/ec2_oct.c68
-rw-r--r--contrib/libs/openssl/crypto/ec/ec_ameth.c44
-rw-r--r--contrib/libs/openssl/crypto/ec/ec_asn1.c72
-rw-r--r--contrib/libs/openssl/crypto/ec/ec_err.c4
-rw-r--r--contrib/libs/openssl/crypto/ec/ec_key.c160
-rw-r--r--contrib/libs/openssl/crypto/ec/ec_lib.c2
-rw-r--r--contrib/libs/openssl/crypto/ec/ec_local.h6
-rw-r--r--contrib/libs/openssl/crypto/ec/ecp_nistp224.c10
-rw-r--r--contrib/libs/openssl/crypto/ec/ecp_nistp521.c34
-rw-r--r--contrib/libs/openssl/crypto/ec/ecp_nistz256.c108
-rw-r--r--contrib/libs/openssl/crypto/engine/README422
-rw-r--r--contrib/libs/openssl/crypto/engine/eng_devcrypto.c30
-rw-r--r--contrib/libs/openssl/crypto/engine/eng_lib.c4
-rw-r--r--contrib/libs/openssl/crypto/err/README88
-rw-r--r--contrib/libs/openssl/crypto/evp/bio_ok.c4
-rw-r--r--contrib/libs/openssl/crypto/evp/e_aes.c186
-rw-r--r--contrib/libs/openssl/crypto/evp/e_camellia.c10
-rw-r--r--contrib/libs/openssl/crypto/evp/encode.c4
-rw-r--r--contrib/libs/openssl/crypto/evp/evp_enc.c56
-rw-r--r--contrib/libs/openssl/crypto/evp/evp_err.c6
-rw-r--r--contrib/libs/openssl/crypto/hmac/hm_ameth.c6
-rw-r--r--contrib/libs/openssl/crypto/mem_sec.c18
-rw-r--r--contrib/libs/openssl/crypto/modes/cbc128.c38
-rw-r--r--contrib/libs/openssl/crypto/modes/ccm128.c34
-rw-r--r--contrib/libs/openssl/crypto/modes/cfb128.c28
-rw-r--r--contrib/libs/openssl/crypto/modes/ctr128.c20
-rw-r--r--contrib/libs/openssl/crypto/modes/gcm128.c34
-rw-r--r--contrib/libs/openssl/crypto/modes/modes_local.h32
-rw-r--r--contrib/libs/openssl/crypto/modes/ofb128.c20
-rw-r--r--contrib/libs/openssl/crypto/modes/xts128.c34
-rw-r--r--contrib/libs/openssl/crypto/o_str.c4
-rw-r--r--contrib/libs/openssl/crypto/o_time.c8
-rw-r--r--contrib/libs/openssl/crypto/objects/README88
-rw-r--r--contrib/libs/openssl/crypto/objects/obj_dat.h2
-rw-r--r--contrib/libs/openssl/crypto/objects/obj_xref.h2
-rw-r--r--contrib/libs/openssl/crypto/pem/pem_err.c10
-rw-r--r--contrib/libs/openssl/crypto/pem/pem_lib.c48
-rw-r--r--contrib/libs/openssl/crypto/pem/pem_pkey.c14
-rw-r--r--contrib/libs/openssl/crypto/pem/pvkfmt.c12
-rw-r--r--contrib/libs/openssl/crypto/pkcs12/p12_key.c4
-rw-r--r--contrib/libs/openssl/crypto/pkcs7/pk7_smime.c4
-rw-r--r--contrib/libs/openssl/crypto/poly1305/poly1305_ameth.c4
-rw-r--r--contrib/libs/openssl/crypto/ppccap.c50
-rw-r--r--contrib/libs/openssl/crypto/rand/drbg_ctr.c258
-rw-r--r--contrib/libs/openssl/crypto/rand/drbg_lib.c54
-rw-r--r--contrib/libs/openssl/crypto/rand/rand_lib.c12
-rw-r--r--contrib/libs/openssl/crypto/rand/rand_local.h26
-rw-r--r--contrib/libs/openssl/crypto/rand/rand_unix.c52
-rw-r--r--contrib/libs/openssl/crypto/rand/randfile.c4
-rw-r--r--contrib/libs/openssl/crypto/rsa/rsa_ameth.c20
-rw-r--r--contrib/libs/openssl/crypto/rsa/rsa_prn.c10
-rw-r--r--contrib/libs/openssl/crypto/rsa/rsa_ssl.c18
-rw-r--r--contrib/libs/openssl/crypto/siphash/siphash_ameth.c4
-rw-r--r--contrib/libs/openssl/crypto/sm2/sm2_crypt.c24
-rw-r--r--contrib/libs/openssl/crypto/sm2/sm2_pmeth.c4
-rw-r--r--contrib/libs/openssl/crypto/sparcv9cap.c4
-rw-r--r--contrib/libs/openssl/crypto/srp/srp_lib.c18
-rw-r--r--contrib/libs/openssl/crypto/srp/srp_vfy.c14
-rw-r--r--contrib/libs/openssl/crypto/store/loader_file.c78
-rw-r--r--contrib/libs/openssl/crypto/store/store_lib.c12
-rw-r--r--contrib/libs/openssl/crypto/ts/ts_rsp_sign.c4
-rw-r--r--contrib/libs/openssl/crypto/ts/ts_rsp_verify.c4
-rw-r--r--contrib/libs/openssl/crypto/ts/ts_verify_ctx.c6
-rw-r--r--contrib/libs/openssl/crypto/ui/ui_openssl.c22
-rw-r--r--contrib/libs/openssl/crypto/uid.c14
-rw-r--r--contrib/libs/openssl/crypto/whrlpool/wp_block.c48
-rw-r--r--contrib/libs/openssl/crypto/x509/t_x509.c6
-rw-r--r--contrib/libs/openssl/crypto/x509/x509_att.c4
-rw-r--r--contrib/libs/openssl/crypto/x509/x509_cmp.c34
-rw-r--r--contrib/libs/openssl/crypto/x509/x509_err.c4
-rw-r--r--contrib/libs/openssl/crypto/x509/x509_local.h6
-rw-r--r--contrib/libs/openssl/crypto/x509/x509_req.c26
-rw-r--r--contrib/libs/openssl/crypto/x509/x509_txt.c6
-rw-r--r--contrib/libs/openssl/crypto/x509/x509_vfy.c316
-rw-r--r--contrib/libs/openssl/crypto/x509/x509_vpm.c6
-rw-r--r--contrib/libs/openssl/crypto/x509/x_all.c4
-rw-r--r--contrib/libs/openssl/crypto/x509/x_attrib.c8
-rw-r--r--contrib/libs/openssl/crypto/x509/x_pubkey.c12
-rw-r--r--contrib/libs/openssl/crypto/x509v3/pcy_data.c4
-rw-r--r--contrib/libs/openssl/crypto/x509v3/v3_akey.c68
-rw-r--r--contrib/libs/openssl/crypto/x509v3/v3_alt.c18
-rw-r--r--contrib/libs/openssl/crypto/x509v3/v3_cpols.c14
-rw-r--r--contrib/libs/openssl/crypto/x509v3/v3_genn.c92
-rw-r--r--contrib/libs/openssl/crypto/x509v3/v3_ncons.c106
-rw-r--r--contrib/libs/openssl/crypto/x509v3/v3_pci.c6
-rw-r--r--contrib/libs/openssl/crypto/x509v3/v3_purp.c116
-rw-r--r--contrib/libs/openssl/crypto/x509v3/v3_utl.c94
-rw-r--r--contrib/libs/openssl/crypto/x509v3/v3err.c10
-rw-r--r--contrib/libs/openssl/crypto/ya.make1000
139 files changed, 4657 insertions, 4657 deletions
diff --git a/contrib/libs/openssl/crypto/.yandex_meta/licenses.list.txt b/contrib/libs/openssl/crypto/.yandex_meta/licenses.list.txt
index be2bf5ba2d..acd084e04f 100644
--- a/contrib/libs/openssl/crypto/.yandex_meta/licenses.list.txt
+++ b/contrib/libs/openssl/crypto/.yandex_meta/licenses.list.txt
@@ -1,968 +1,968 @@
-====================Apache-2.0====================
- * Licensed under the Apache License, Version 2.0 (the "License");
- *
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
-
-
-====================BSD-3-Clause====================
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * 3. Neither the name of the Institute nor the names of its contributors
- * may be used to endorse or promote products derived from this software
- * without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
-
-
-====================BSD-3-Clause====================
-# define CHECK_BSD_STYLE_MACROS
-
-
-====================BSD-3-Clause====================
-# if !defined(CHECK_BSD_STYLE_MACROS) || defined(CRYPTO_RIPEMD160)
-
-
-====================BSD-3-Clause====================
-#if !defined(CHECK_BSD_STYLE_MACROS) || defined(CRYPTO_AES_CTR)
-
-
-====================BSD-3-Clause====================
-#if !defined(CHECK_BSD_STYLE_MACROS) || defined(CRYPTO_AES_ECB)
-
-
-====================BSD-3-Clause====================
-#if !defined(CHECK_BSD_STYLE_MACROS) || defined(CRYPTO_SHA2_224)
-
-
-====================BSD-3-Clause====================
-#if !defined(CHECK_BSD_STYLE_MACROS) || defined(CRYPTO_SHA2_256)
-
-
-====================BSD-3-Clause====================
-#if !defined(CHECK_BSD_STYLE_MACROS) || defined(CRYPTO_SHA2_384)
-
-
-====================BSD-3-Clause====================
-#if !defined(CHECK_BSD_STYLE_MACROS) || defined(CRYPTO_SHA2_512)
-
-
-====================BSD-Source-Code====================
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Neither the name of author nor the names of its contributors may
- * be used to endorse or promote products derived from this software
- * without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED. IN NO EVENT SHALL AUTHOR OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
-
-
-====================CC0-1.0====================
- To the extent possible under law, the author(s) have dedicated all copyright
- and related and neighboring rights to this software to the public domain
- worldwide. This software is distributed without any warranty.
-
- You should have received a copy of the CC0 Public Domain Dedication along
- with this software. If not, see
- <http://creativecommons.org/publicdomain/zero/1.0/>.
-
-
-====================COPYRIGHT====================
- Copyright (c) 2012-2016 Jean-Philippe Aumasson
- Copyright (c) 2012-2014 Daniel J. Bernstein
-
-
-====================COPYRIGHT====================
- * Copyright (C) 2017 National Security Research Institute. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright (c) 2002, Oracle and/or its affiliates. All rights reserved
-
-
-====================COPYRIGHT====================
- * Copyright (c) 2004 Kungliga Tekniska Högskolan
- * (Royal Institute of Technology, Stockholm, Sweden).
- * All rights reserved.
-
-
-====================COPYRIGHT====================
- * Copyright (c) 2004, 2018, Richard Levitte <richard@levitte.org>
- * All rights reserved.
-
-
-====================COPYRIGHT====================
- * Copyright (c) 2004, EdelKey Project. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright (c) 2004, Richard Levitte <richard@levitte.org>
- * All rights reserved.
-
-
-====================COPYRIGHT====================
- * Copyright (c) 2007 KISA(Korea Information Security Agency). All rights reserved.
-
-
-====================COPYRIGHT====================
- * Copyright (c) 2012, Intel Corporation. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright (c) 2014, Intel Corporation. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright (c) 2015, CloudFlare, Inc.
-
-
-====================COPYRIGHT====================
- * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1995-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1995-2017 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1995-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1995-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1998-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1998-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1998-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1998-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1998-2021 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1999-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1999-2017 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1999-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1999-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1999-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2000-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2000-2017 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2000-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2000-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2000-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2000-2021 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2001-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2001-2017 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2001-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2001-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2001-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2001-2021 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2002-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2002-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2002-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2002-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2002-2021 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2003-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2003-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2003-2021 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2004-2014, Akamai Technologies. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2004-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2004-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2004-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2004-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2004-2021 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2005-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2005-2017 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2005-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2005-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2005-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2006 NTT (Nippon Telegraph and Telephone Corporation) .
- * ALL RIGHTS RESERVED.
-
-
-====================COPYRIGHT====================
- * Copyright 2006-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2006-2017 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2006-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2006-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2006-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2006-2021 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2007-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2007-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2007-2021 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2008-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2008-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2008-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2008-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2008-2021 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2009-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2009-2021 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2010-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2010-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2010-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2010-2021 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2011-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2011-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2011-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2011-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2011-2021 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2012-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2012-2017 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2013-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2013-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2013-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2014 Cryptography Research, Inc.
-
-
-====================COPYRIGHT====================
- * Copyright 2014-2016 Cryptography Research, Inc.
-
-
-====================COPYRIGHT====================
- * Copyright 2014-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2014-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2014-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2015 Cryptography Research, Inc.
-
-
-====================COPYRIGHT====================
- * Copyright 2015-2016 Cryptography Research, Inc.
-
-
-====================COPYRIGHT====================
- * Copyright 2015-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2015-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2015-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2015-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2016 Cryptography Research, Inc.
-
-
-====================COPYRIGHT====================
- * Copyright 2016 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2016-2017 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2016-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2016-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2016-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2017 BaishanCloud. All rights reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2017 Ribose Inc. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2017 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2017-2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2017-2019 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2017-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2017-2021 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright 2018 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================COPYRIGHT====================
- * Copyright Patrick Powell 1995
- * This code is based on code written by Patrick Powell <papowell@astart.com>
- * It may be used for any purpose as long as this notice remains intact
- * on all source code distributions.
-
-
-====================COPYRIGHT====================
- * Derived from the BLAKE2 reference implementation written by Samuel Neves.
- * Copyright 2012, Samuel Neves <sneves@dei.uc.pt>
- * More information about the BLAKE2 hash function and its implementations
- * can be found at https://blake2.net.
-
-
-====================COPYRIGHT====================
-/* Copyright 2011 Google Inc.
-
-
-====================COPYRIGHT====================
-// Copyright 2014-2020 The OpenSSL Project Authors. All Rights Reserved.
-
-
-====================File: AUTHORS====================
-# This is the list of OpenSSL authors for copyright purposes.
-#
-# This does not necessarily list everyone who has contributed code, since in
-# some cases, their employer may be the copyright holder. To see the full list
-# of contributors, see the revision history in source control.
-OpenSSL Software Services, Inc.
-OpenSSL Software Foundation, Inc.
-
-# Individuals
-Andy Polyakov
-Ben Laurie
-Ben Kaduk
-Bernd Edlinger
-Bodo Möller
-David Benjamin
-David von Oheimb
-Dmitry Belyavskiy (Дмитрий Белявский)
-Emilia Käsper
-Eric Young
-Geoff Thorpe
-Holger Reif
-Kurt Roeckx
-Lutz Jänicke
-Mark J. Cox
-Matt Caswell
-Matthias St. Pierre
-Nicola Tuveri
-Nils Larsch
-Patrick Steuer
-Paul Dale
-Paul C. Sutton
-Paul Yang
-Ralf S. Engelschall
-Rich Salz
-Richard Levitte
-Shane Lontis
-Stephen Henson
-Steve Marquess
-Tim Hudson
-Tomáš Mráz
-Ulf Möller
-Viktor Dukhovni
-
-
-====================File: LICENSE====================
-
- LICENSE ISSUES
- ==============
-
- The OpenSSL toolkit stays under a double license, i.e. both the conditions of
- the OpenSSL License and the original SSLeay license apply to the toolkit.
- See below for the actual license texts.
-
- OpenSSL License
- ---------------
-
-/* ====================================================================
- * Copyright (c) 1998-2019 The OpenSSL Project. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in
- * the documentation and/or other materials provided with the
- * distribution.
- *
- * 3. All advertising materials mentioning features or use of this
- * software must display the following acknowledgment:
- * "This product includes software developed by the OpenSSL Project
- * for use in the OpenSSL Toolkit. (http://www.openssl.org/)"
- *
- * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to
- * endorse or promote products derived from this software without
- * prior written permission. For written permission, please contact
- * openssl-core@openssl.org.
- *
- * 5. Products derived from this software may not be called "OpenSSL"
- * nor may "OpenSSL" appear in their names without prior written
- * permission of the OpenSSL Project.
- *
- * 6. Redistributions of any form whatsoever must retain the following
- * acknowledgment:
- * "This product includes software developed by the OpenSSL Project
- * for use in the OpenSSL Toolkit (http://www.openssl.org/)"
- *
- * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY
- * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR
- * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
- * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
- * OF THE POSSIBILITY OF SUCH DAMAGE.
- * ====================================================================
- *
- * This product includes cryptographic software written by Eric Young
- * (eay@cryptsoft.com). This product includes software written by Tim
- * Hudson (tjh@cryptsoft.com).
- *
- */
-
- Original SSLeay License
- -----------------------
-
-/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
- * All rights reserved.
- *
- * This package is an SSL implementation written
- * by Eric Young (eay@cryptsoft.com).
- * The implementation was written so as to conform with Netscapes SSL.
- *
- * This library is free for commercial and non-commercial use as long as
- * the following conditions are aheared to. The following conditions
- * apply to all code found in this distribution, be it the RC4, RSA,
- * lhash, DES, etc., code; not just the SSL code. The SSL documentation
- * included with this distribution is covered by the same copyright terms
- * except that the holder is Tim Hudson (tjh@cryptsoft.com).
- *
- * Copyright remains Eric Young's, and as such any Copyright notices in
- * the code are not to be removed.
- * If this package is used in a product, Eric Young should be given attribution
- * as the author of the parts of the library used.
- * This can be in the form of a textual message at program startup or
- * in documentation (online or textual) provided with the package.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * "This product includes cryptographic software written by
- * Eric Young (eay@cryptsoft.com)"
- * The word 'cryptographic' can be left out if the rouines from the library
- * being used are not cryptographic related :-).
- * 4. If you include any Windows specific code (or a derivative thereof) from
- * the apps directory (application code) you must include an acknowledgement:
- * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)"
- *
- * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- *
- * The licence and distribution terms for any publically available version or
- * derivative of this code cannot be changed. i.e. this code cannot simply be
- * copied and put under another distribution licence
- * [including the GNU Public Licence.]
- */
-
-
-
-====================OpenSSL====================
- * Licensed under the OpenSSL license (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
-
-
-====================OpenSSL====================
- * Licensed under the OpenSSL licenses, (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- * https://www.openssl.org/source/license.html
- * or in the file LICENSE in the source distribution.
-
-
-====================OpenSSL====================
- * Rights for redistribution and usage in source and binary forms are
- * granted according to the OpenSSL license. Warranty of any kind is
- * disclaimed.
-
-
-====================OpenSSL====================
-;; Licensed under the OpenSSL license (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
-
-
-====================OpenSSL====================
-;; Rights for redistribution and usage in source and binary forms are
-;; granted according to the OpenSSL license. Warranty of any kind is
-;; disclaimed.
-
-
-====================OpenSSL====================
-Licensed under the OpenSSL license (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
-L<https://www.openssl.org/source/license.html>.
-
-
-====================OpenSSL AND BSD-2-Clause====================
- * Licensed under the OpenSSL license (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
- */
-
-/*
- * This file is dual-licensed and is also available under the following
- * terms:
- *
- * Copyright (c) 2004, 2018, Richard Levitte <richard@levitte.org>
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-
-====================OpenSSL AND BSD-2-Clause====================
- * Licensed under the OpenSSL license (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
- */
-
-/*
- * This file is dual-licensed and is also available under the following
- * terms:
- *
- * Copyright (c) 2004, Richard Levitte <richard@levitte.org>
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-
-====================OpenSSL AND BSD-2-Clause====================
- * Licensed under the OpenSSL license (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
- */
-
-/*
- * This file is dual-licensed and is also available under the following
- * terms:
- *
- * Copyright (c) 2004, Richard Levitte <richard@levitte.org>
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- * notice, this list of conditions and the following disclaimer in the
- * documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
-
-
-====================Public-Domain====================
- * Public domain version is distributed above.
-
-
-====================Public-Domain====================
- * THIS SOFTWARE IS PROVIDED BY THE AUTHORS ''AS IS'' AND ANY EXPRESS
- * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE
- * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
- * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-
-====================Public-Domain====================
- * This code is hereby placed in the public domain.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHORS ''AS IS'' AND ANY EXPRESS
- * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE
- * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
- * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
- * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
- * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
- * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-
-====================Public-Domain====================
-/* Adapted from the public domain code by D. Bernstein from SUPERCOP. */
-
-
-====================Snprintf====================
- * It may be used for any purpose as long as this notice remains intact
- * on all source code distributions.
+====================Apache-2.0====================
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ *
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+
+
+====================BSD-3-Clause====================
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * 3. Neither the name of the Institute nor the names of its contributors
+ * may be used to endorse or promote products derived from this software
+ * without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE INSTITUTE AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE INSTITUTE OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+
+
+====================BSD-3-Clause====================
+# define CHECK_BSD_STYLE_MACROS
+
+
+====================BSD-3-Clause====================
+# if !defined(CHECK_BSD_STYLE_MACROS) || defined(CRYPTO_RIPEMD160)
+
+
+====================BSD-3-Clause====================
+#if !defined(CHECK_BSD_STYLE_MACROS) || defined(CRYPTO_AES_CTR)
+
+
+====================BSD-3-Clause====================
+#if !defined(CHECK_BSD_STYLE_MACROS) || defined(CRYPTO_AES_ECB)
+
+
+====================BSD-3-Clause====================
+#if !defined(CHECK_BSD_STYLE_MACROS) || defined(CRYPTO_SHA2_224)
+
+
+====================BSD-3-Clause====================
+#if !defined(CHECK_BSD_STYLE_MACROS) || defined(CRYPTO_SHA2_256)
+
+
+====================BSD-3-Clause====================
+#if !defined(CHECK_BSD_STYLE_MACROS) || defined(CRYPTO_SHA2_384)
+
+
+====================BSD-3-Clause====================
+#if !defined(CHECK_BSD_STYLE_MACROS) || defined(CRYPTO_SHA2_512)
+
+
+====================BSD-Source-Code====================
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Neither the name of author nor the names of its contributors may
+ * be used to endorse or promote products derived from this software
+ * without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+
+
+====================CC0-1.0====================
+ To the extent possible under law, the author(s) have dedicated all copyright
+ and related and neighboring rights to this software to the public domain
+ worldwide. This software is distributed without any warranty.
+
+ You should have received a copy of the CC0 Public Domain Dedication along
+ with this software. If not, see
+ <http://creativecommons.org/publicdomain/zero/1.0/>.
+
+
+====================COPYRIGHT====================
+ Copyright (c) 2012-2016 Jean-Philippe Aumasson
+ Copyright (c) 2012-2014 Daniel J. Bernstein
+
+
+====================COPYRIGHT====================
+ * Copyright (C) 2017 National Security Research Institute. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright (c) 2002, Oracle and/or its affiliates. All rights reserved
+
+
+====================COPYRIGHT====================
+ * Copyright (c) 2004 Kungliga Tekniska Högskolan
+ * (Royal Institute of Technology, Stockholm, Sweden).
+ * All rights reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright (c) 2004, 2018, Richard Levitte <richard@levitte.org>
+ * All rights reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright (c) 2004, EdelKey Project. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright (c) 2004, Richard Levitte <richard@levitte.org>
+ * All rights reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright (c) 2007 KISA(Korea Information Security Agency). All rights reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright (c) 2012, Intel Corporation. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright (c) 2014, Intel Corporation. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright (c) 2015, CloudFlare, Inc.
+
+
+====================COPYRIGHT====================
+ * Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1995-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1995-2017 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1995-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1995-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1998-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1998-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1998-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1998-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1998-2021 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1999-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1999-2017 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1999-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1999-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1999-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2000-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2000-2017 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2000-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2000-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2000-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2000-2021 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2001-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2001-2017 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2001-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2001-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2001-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2001-2021 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2002-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2002-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2002-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2002-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2002-2021 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2003-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2003-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2003-2021 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2004-2014, Akamai Technologies. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2004-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2004-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2004-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2004-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2004-2021 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2005-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2005-2017 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2005-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2005-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2005-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2006 NTT (Nippon Telegraph and Telephone Corporation) .
+ * ALL RIGHTS RESERVED.
+
+
+====================COPYRIGHT====================
+ * Copyright 2006-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2006-2017 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2006-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2006-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2006-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2006-2021 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2007-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2007-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2007-2021 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2008-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2008-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2008-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2008-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2008-2021 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2009-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2009-2021 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2010-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2010-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2010-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2010-2021 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2011-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2011-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2011-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2011-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2011-2021 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2012-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2012-2017 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2013-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2013-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2013-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2014 Cryptography Research, Inc.
+
+
+====================COPYRIGHT====================
+ * Copyright 2014-2016 Cryptography Research, Inc.
+
+
+====================COPYRIGHT====================
+ * Copyright 2014-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2014-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2014-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2015 Cryptography Research, Inc.
+
+
+====================COPYRIGHT====================
+ * Copyright 2015-2016 Cryptography Research, Inc.
+
+
+====================COPYRIGHT====================
+ * Copyright 2015-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2015-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2015-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2015-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2016 Cryptography Research, Inc.
+
+
+====================COPYRIGHT====================
+ * Copyright 2016 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2016-2017 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2016-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2016-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2016-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2017 BaishanCloud. All rights reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2017 Ribose Inc. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2017 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2017-2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2017-2019 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2017-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2017-2021 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright 2018 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================COPYRIGHT====================
+ * Copyright Patrick Powell 1995
+ * This code is based on code written by Patrick Powell <papowell@astart.com>
+ * It may be used for any purpose as long as this notice remains intact
+ * on all source code distributions.
+
+
+====================COPYRIGHT====================
+ * Derived from the BLAKE2 reference implementation written by Samuel Neves.
+ * Copyright 2012, Samuel Neves <sneves@dei.uc.pt>
+ * More information about the BLAKE2 hash function and its implementations
+ * can be found at https://blake2.net.
+
+
+====================COPYRIGHT====================
+/* Copyright 2011 Google Inc.
+
+
+====================COPYRIGHT====================
+// Copyright 2014-2020 The OpenSSL Project Authors. All Rights Reserved.
+
+
+====================File: AUTHORS====================
+# This is the list of OpenSSL authors for copyright purposes.
+#
+# This does not necessarily list everyone who has contributed code, since in
+# some cases, their employer may be the copyright holder. To see the full list
+# of contributors, see the revision history in source control.
+OpenSSL Software Services, Inc.
+OpenSSL Software Foundation, Inc.
+
+# Individuals
+Andy Polyakov
+Ben Laurie
+Ben Kaduk
+Bernd Edlinger
+Bodo Möller
+David Benjamin
+David von Oheimb
+Dmitry Belyavskiy (Дмитрий Белявский)
+Emilia Käsper
+Eric Young
+Geoff Thorpe
+Holger Reif
+Kurt Roeckx
+Lutz Jänicke
+Mark J. Cox
+Matt Caswell
+Matthias St. Pierre
+Nicola Tuveri
+Nils Larsch
+Patrick Steuer
+Paul Dale
+Paul C. Sutton
+Paul Yang
+Ralf S. Engelschall
+Rich Salz
+Richard Levitte
+Shane Lontis
+Stephen Henson
+Steve Marquess
+Tim Hudson
+Tomáš Mráz
+Ulf Möller
+Viktor Dukhovni
+
+
+====================File: LICENSE====================
+
+ LICENSE ISSUES
+ ==============
+
+ The OpenSSL toolkit stays under a double license, i.e. both the conditions of
+ the OpenSSL License and the original SSLeay license apply to the toolkit.
+ See below for the actual license texts.
+
+ OpenSSL License
+ ---------------
+
+/* ====================================================================
+ * Copyright (c) 1998-2019 The OpenSSL Project. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in
+ * the documentation and/or other materials provided with the
+ * distribution.
+ *
+ * 3. All advertising materials mentioning features or use of this
+ * software must display the following acknowledgment:
+ * "This product includes software developed by the OpenSSL Project
+ * for use in the OpenSSL Toolkit. (http://www.openssl.org/)"
+ *
+ * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to
+ * endorse or promote products derived from this software without
+ * prior written permission. For written permission, please contact
+ * openssl-core@openssl.org.
+ *
+ * 5. Products derived from this software may not be called "OpenSSL"
+ * nor may "OpenSSL" appear in their names without prior written
+ * permission of the OpenSSL Project.
+ *
+ * 6. Redistributions of any form whatsoever must retain the following
+ * acknowledgment:
+ * "This product includes software developed by the OpenSSL Project
+ * for use in the OpenSSL Toolkit (http://www.openssl.org/)"
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY
+ * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR
+ * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+ * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
+ * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
+ * OF THE POSSIBILITY OF SUCH DAMAGE.
+ * ====================================================================
+ *
+ * This product includes cryptographic software written by Eric Young
+ * (eay@cryptsoft.com). This product includes software written by Tim
+ * Hudson (tjh@cryptsoft.com).
+ *
+ */
+
+ Original SSLeay License
+ -----------------------
+
+/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
+ * All rights reserved.
+ *
+ * This package is an SSL implementation written
+ * by Eric Young (eay@cryptsoft.com).
+ * The implementation was written so as to conform with Netscapes SSL.
+ *
+ * This library is free for commercial and non-commercial use as long as
+ * the following conditions are aheared to. The following conditions
+ * apply to all code found in this distribution, be it the RC4, RSA,
+ * lhash, DES, etc., code; not just the SSL code. The SSL documentation
+ * included with this distribution is covered by the same copyright terms
+ * except that the holder is Tim Hudson (tjh@cryptsoft.com).
+ *
+ * Copyright remains Eric Young's, and as such any Copyright notices in
+ * the code are not to be removed.
+ * If this package is used in a product, Eric Young should be given attribution
+ * as the author of the parts of the library used.
+ * This can be in the form of a textual message at program startup or
+ * in documentation (online or textual) provided with the package.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. All advertising materials mentioning features or use of this software
+ * must display the following acknowledgement:
+ * "This product includes cryptographic software written by
+ * Eric Young (eay@cryptsoft.com)"
+ * The word 'cryptographic' can be left out if the rouines from the library
+ * being used are not cryptographic related :-).
+ * 4. If you include any Windows specific code (or a derivative thereof) from
+ * the apps directory (application code) you must include an acknowledgement:
+ * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)"
+ *
+ * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * The licence and distribution terms for any publically available version or
+ * derivative of this code cannot be changed. i.e. this code cannot simply be
+ * copied and put under another distribution licence
+ * [including the GNU Public Licence.]
+ */
+
+
+
+====================OpenSSL====================
+ * Licensed under the OpenSSL license (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
+
+
+====================OpenSSL====================
+ * Licensed under the OpenSSL licenses, (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ * https://www.openssl.org/source/license.html
+ * or in the file LICENSE in the source distribution.
+
+
+====================OpenSSL====================
+ * Rights for redistribution and usage in source and binary forms are
+ * granted according to the OpenSSL license. Warranty of any kind is
+ * disclaimed.
+
+
+====================OpenSSL====================
+;; Licensed under the OpenSSL license (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
+
+
+====================OpenSSL====================
+;; Rights for redistribution and usage in source and binary forms are
+;; granted according to the OpenSSL license. Warranty of any kind is
+;; disclaimed.
+
+
+====================OpenSSL====================
+Licensed under the OpenSSL license (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
+L<https://www.openssl.org/source/license.html>.
+
+
+====================OpenSSL AND BSD-2-Clause====================
+ * Licensed under the OpenSSL license (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
+ */
+
+/*
+ * This file is dual-licensed and is also available under the following
+ * terms:
+ *
+ * Copyright (c) 2004, 2018, Richard Levitte <richard@levitte.org>
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+
+====================OpenSSL AND BSD-2-Clause====================
+ * Licensed under the OpenSSL license (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
+ */
+
+/*
+ * This file is dual-licensed and is also available under the following
+ * terms:
+ *
+ * Copyright (c) 2004, Richard Levitte <richard@levitte.org>
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+
+====================OpenSSL AND BSD-2-Clause====================
+ * Licensed under the OpenSSL license (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
+ */
+
+/*
+ * This file is dual-licensed and is also available under the following
+ * terms:
+ *
+ * Copyright (c) 2004, Richard Levitte <richard@levitte.org>
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+
+
+====================Public-Domain====================
+ * Public domain version is distributed above.
+
+
+====================Public-Domain====================
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHORS ''AS IS'' AND ANY EXPRESS
+ * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+ * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+ * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
+ * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+
+====================Public-Domain====================
+ * This code is hereby placed in the public domain.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHORS ''AS IS'' AND ANY EXPRESS
+ * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+ * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+ * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
+ * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+
+====================Public-Domain====================
+/* Adapted from the public domain code by D. Bernstein from SUPERCOP. */
+
+
+====================Snprintf====================
+ * It may be used for any purpose as long as this notice remains intact
+ * on all source code distributions.
diff --git a/contrib/libs/openssl/crypto/aes/aes_ige.c b/contrib/libs/openssl/crypto/aes/aes_ige.c
index d7be4494c1..804b3a723d 100644
--- a/contrib/libs/openssl/crypto/aes/aes_ige.c
+++ b/contrib/libs/openssl/crypto/aes/aes_ige.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2006-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2006-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -19,15 +19,15 @@
# define UNALIGNED_MEMOPS_ARE_FAST 0
#endif
-#define N_WORDS (AES_BLOCK_SIZE / sizeof(unsigned long))
-typedef struct {
- unsigned long data[N_WORDS];
-#if defined(__GNUC__) && UNALIGNED_MEMOPS_ARE_FAST
-} aes_block_t __attribute((__aligned__(1)));
-#else
-} aes_block_t;
-#endif
-
+#define N_WORDS (AES_BLOCK_SIZE / sizeof(unsigned long))
+typedef struct {
+ unsigned long data[N_WORDS];
+#if defined(__GNUC__) && UNALIGNED_MEMOPS_ARE_FAST
+} aes_block_t __attribute((__aligned__(1)));
+#else
+} aes_block_t;
+#endif
+
#if UNALIGNED_MEMOPS_ARE_FAST
# define load_block(d, s) (d) = *(const aes_block_t *)(s)
# define store_block(d, s) *(aes_block_t *)(d) = (s)
diff --git a/contrib/libs/openssl/crypto/armcap.c b/contrib/libs/openssl/crypto/armcap.c
index 1fd177151f..a96804c706 100644
--- a/contrib/libs/openssl/crypto/armcap.c
+++ b/contrib/libs/openssl/crypto/armcap.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2011-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2011-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -68,39 +68,39 @@ void OPENSSL_cpuid_setup(void) __attribute__ ((constructor));
# include <sys/auxv.h>
# define OSSL_IMPLEMENT_GETAUXVAL
# endif
-# elif defined(__ANDROID_API__)
-/* see https://developer.android.google.cn/ndk/guides/cpu-features */
-# if __ANDROID_API__ >= 18
-# include <sys/auxv.h>
-# define OSSL_IMPLEMENT_GETAUXVAL
-# endif
+# elif defined(__ANDROID_API__)
+/* see https://developer.android.google.cn/ndk/guides/cpu-features */
+# if __ANDROID_API__ >= 18
+# include <sys/auxv.h>
+# define OSSL_IMPLEMENT_GETAUXVAL
+# endif
+# endif
+# if defined(__FreeBSD__)
+# include <sys/param.h>
+# if __FreeBSD_version >= 1200000
+# include <sys/auxv.h>
+# define OSSL_IMPLEMENT_GETAUXVAL
+
+static unsigned long getauxval(unsigned long key)
+{
+ unsigned long val = 0ul;
+
+ if (elf_aux_info((int)key, &val, sizeof(val)) != 0)
+ return 0ul;
+
+ return val;
+}
+# endif
# endif
-# if defined(__FreeBSD__)
-# include <sys/param.h>
-# if __FreeBSD_version >= 1200000
-# include <sys/auxv.h>
-# define OSSL_IMPLEMENT_GETAUXVAL
-
-static unsigned long getauxval(unsigned long key)
-{
- unsigned long val = 0ul;
-
- if (elf_aux_info((int)key, &val, sizeof(val)) != 0)
- return 0ul;
-
- return val;
-}
-# endif
-# endif
-
-/*
- * Android: according to https://developer.android.com/ndk/guides/cpu-features,
- * getauxval is supported starting with API level 18
- */
-# if defined(__ANDROID__) && defined(__ANDROID_API__) && __ANDROID_API__ >= 18
-# include <sys/auxv.h>
-# define OSSL_IMPLEMENT_GETAUXVAL
-# endif
+
+/*
+ * Android: according to https://developer.android.com/ndk/guides/cpu-features,
+ * getauxval is supported starting with API level 18
+ */
+# if defined(__ANDROID__) && defined(__ANDROID_API__) && __ANDROID_API__ >= 18
+# include <sys/auxv.h>
+# define OSSL_IMPLEMENT_GETAUXVAL
+# endif
/*
* ARM puts the feature bits for Crypto Extensions in AT_HWCAP2, whereas
diff --git a/contrib/libs/openssl/crypto/asn1/a_object.c b/contrib/libs/openssl/crypto/asn1/a_object.c
index 3f1fec4677..8ade9e50a7 100644
--- a/contrib/libs/openssl/crypto/asn1/a_object.c
+++ b/contrib/libs/openssl/crypto/asn1/a_object.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -290,9 +290,9 @@ ASN1_OBJECT *c2i_ASN1_OBJECT(ASN1_OBJECT **a, const unsigned char **pp,
!((*a)->flags & ASN1_OBJECT_FLAG_DYNAMIC)) {
if ((ret = ASN1_OBJECT_new()) == NULL)
return NULL;
- } else {
+ } else {
ret = (*a);
- }
+ }
p = *pp;
/* detach data from object */
@@ -310,12 +310,12 @@ ASN1_OBJECT *c2i_ASN1_OBJECT(ASN1_OBJECT **a, const unsigned char **pp,
ret->flags |= ASN1_OBJECT_FLAG_DYNAMIC_DATA;
}
memcpy(data, p, length);
- /* If there are dynamic strings, free them here, and clear the flag */
- if ((ret->flags & ASN1_OBJECT_FLAG_DYNAMIC_STRINGS) != 0) {
- OPENSSL_free((char *)ret->sn);
- OPENSSL_free((char *)ret->ln);
- ret->flags &= ~ASN1_OBJECT_FLAG_DYNAMIC_STRINGS;
- }
+ /* If there are dynamic strings, free them here, and clear the flag */
+ if ((ret->flags & ASN1_OBJECT_FLAG_DYNAMIC_STRINGS) != 0) {
+ OPENSSL_free((char *)ret->sn);
+ OPENSSL_free((char *)ret->ln);
+ ret->flags &= ~ASN1_OBJECT_FLAG_DYNAMIC_STRINGS;
+ }
/* reattach data to object, after which it remains const */
ret->data = data;
ret->length = length;
diff --git a/contrib/libs/openssl/crypto/asn1/a_strex.c b/contrib/libs/openssl/crypto/asn1/a_strex.c
index 1bfd15089d..284dde274c 100644
--- a/contrib/libs/openssl/crypto/asn1/a_strex.c
+++ b/contrib/libs/openssl/crypto/asn1/a_strex.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2000-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2000-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -280,8 +280,8 @@ static int do_dump(unsigned long lflags, char_io *io_ch, void *arg,
t.type = str->type;
t.value.ptr = (char *)str;
der_len = i2d_ASN1_TYPE(&t, NULL);
- if (der_len <= 0)
- return -1;
+ if (der_len <= 0)
+ return -1;
if ((der_buf = OPENSSL_malloc(der_len)) == NULL) {
ASN1err(ASN1_F_DO_DUMP, ERR_R_MALLOC_FAILURE);
return -1;
diff --git a/contrib/libs/openssl/crypto/asn1/asn1_err.c b/contrib/libs/openssl/crypto/asn1/asn1_err.c
index 64aeb0e688..cc0a59ca4c 100644
--- a/contrib/libs/openssl/crypto/asn1/asn1_err.c
+++ b/contrib/libs/openssl/crypto/asn1/asn1_err.c
@@ -1,6 +1,6 @@
/*
* Generated by util/mkerr.pl DO NOT EDIT
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -49,7 +49,7 @@ static const ERR_STRING_DATA ASN1_str_functs[] = {
"asn1_item_embed_d2i"},
{ERR_PACK(ERR_LIB_ASN1, ASN1_F_ASN1_ITEM_EMBED_NEW, 0),
"asn1_item_embed_new"},
- {ERR_PACK(ERR_LIB_ASN1, ASN1_F_ASN1_ITEM_EX_I2D, 0), "ASN1_item_ex_i2d"},
+ {ERR_PACK(ERR_LIB_ASN1, ASN1_F_ASN1_ITEM_EX_I2D, 0), "ASN1_item_ex_i2d"},
{ERR_PACK(ERR_LIB_ASN1, ASN1_F_ASN1_ITEM_FLAGS_I2D, 0),
"asn1_item_flags_i2d"},
{ERR_PACK(ERR_LIB_ASN1, ASN1_F_ASN1_ITEM_I2D_BIO, 0), "ASN1_item_i2d_bio"},
@@ -161,7 +161,7 @@ static const ERR_STRING_DATA ASN1_str_reasons[] = {
"asn1 sig parse error"},
{ERR_PACK(ERR_LIB_ASN1, 0, ASN1_R_AUX_ERROR), "aux error"},
{ERR_PACK(ERR_LIB_ASN1, 0, ASN1_R_BAD_OBJECT_HEADER), "bad object header"},
- {ERR_PACK(ERR_LIB_ASN1, 0, ASN1_R_BAD_TEMPLATE), "bad template"},
+ {ERR_PACK(ERR_LIB_ASN1, 0, ASN1_R_BAD_TEMPLATE), "bad template"},
{ERR_PACK(ERR_LIB_ASN1, 0, ASN1_R_BMPSTRING_IS_WRONG_LENGTH),
"bmpstring is wrong length"},
{ERR_PACK(ERR_LIB_ASN1, 0, ASN1_R_BN_LIB), "bn lib"},
diff --git a/contrib/libs/openssl/crypto/asn1/asn1_lib.c b/contrib/libs/openssl/crypto/asn1/asn1_lib.c
index 7c29024972..3d99d1383d 100644
--- a/contrib/libs/openssl/crypto/asn1/asn1_lib.c
+++ b/contrib/libs/openssl/crypto/asn1/asn1_lib.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -292,12 +292,12 @@ int ASN1_STRING_set(ASN1_STRING *str, const void *_data, int len_in)
}
if ((size_t)str->length <= len || str->data == NULL) {
c = str->data;
-#ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
- /* No NUL terminator in fuzzing builds */
- str->data = OPENSSL_realloc(c, len);
-#else
+#ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
+ /* No NUL terminator in fuzzing builds */
+ str->data = OPENSSL_realloc(c, len);
+#else
str->data = OPENSSL_realloc(c, len + 1);
-#endif
+#endif
if (str->data == NULL) {
ASN1err(ASN1_F_ASN1_STRING_SET, ERR_R_MALLOC_FAILURE);
str->data = c;
@@ -307,13 +307,13 @@ int ASN1_STRING_set(ASN1_STRING *str, const void *_data, int len_in)
str->length = len;
if (data != NULL) {
memcpy(str->data, data, len);
-#ifndef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
- /*
- * Add a NUL terminator. This should not be necessary - but we add it as
- * a safety precaution
- */
+#ifndef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
+ /*
+ * Add a NUL terminator. This should not be necessary - but we add it as
+ * a safety precaution
+ */
str->data[len] = '\0';
-#endif
+#endif
}
return 1;
}
diff --git a/contrib/libs/openssl/crypto/asn1/asn1_par.c b/contrib/libs/openssl/crypto/asn1/asn1_par.c
index 8851a703e8..a32fa47f22 100644
--- a/contrib/libs/openssl/crypto/asn1/asn1_par.c
+++ b/contrib/libs/openssl/crypto/asn1/asn1_par.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -325,7 +325,7 @@ static int asn1_parse2(BIO *bp, const unsigned char **pp, long length,
}
if (BIO_puts(bp, "]") <= 0)
goto end;
- dump_cont = 0;
+ dump_cont = 0;
}
if (!nl) {
diff --git a/contrib/libs/openssl/crypto/asn1/bio_asn1.c b/contrib/libs/openssl/crypto/asn1/bio_asn1.c
index 61aaabaf69..914d77c866 100644
--- a/contrib/libs/openssl/crypto/asn1/bio_asn1.c
+++ b/contrib/libs/openssl/crypto/asn1/bio_asn1.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2006-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2006-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -138,11 +138,11 @@ static int asn1_bio_free(BIO *b)
if (ctx == NULL)
return 0;
- if (ctx->prefix_free != NULL)
- ctx->prefix_free(b, &ctx->ex_buf, &ctx->ex_len, &ctx->ex_arg);
- if (ctx->suffix_free != NULL)
- ctx->suffix_free(b, &ctx->ex_buf, &ctx->ex_len, &ctx->ex_arg);
-
+ if (ctx->prefix_free != NULL)
+ ctx->prefix_free(b, &ctx->ex_buf, &ctx->ex_len, &ctx->ex_arg);
+ if (ctx->suffix_free != NULL)
+ ctx->suffix_free(b, &ctx->ex_buf, &ctx->ex_len, &ctx->ex_arg);
+
OPENSSL_free(ctx->buf);
OPENSSL_free(ctx);
BIO_set_data(b, NULL);
diff --git a/contrib/libs/openssl/crypto/asn1/bio_ndef.c b/contrib/libs/openssl/crypto/asn1/bio_ndef.c
index f15dd74413..760e4846a4 100644
--- a/contrib/libs/openssl/crypto/asn1/bio_ndef.c
+++ b/contrib/libs/openssl/crypto/asn1/bio_ndef.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2008-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2008-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -113,8 +113,8 @@ static int ndef_prefix(BIO *b, unsigned char **pbuf, int *plen, void *parg)
ndef_aux = *(NDEF_SUPPORT **)parg;
derlen = ASN1_item_ndef_i2d(ndef_aux->val, NULL, ndef_aux->it);
- if (derlen < 0)
- return 0;
+ if (derlen < 0)
+ return 0;
if ((p = OPENSSL_malloc(derlen)) == NULL) {
ASN1err(ASN1_F_NDEF_PREFIX, ERR_R_MALLOC_FAILURE);
return 0;
@@ -142,9 +142,9 @@ static int ndef_prefix_free(BIO *b, unsigned char **pbuf, int *plen,
ndef_aux = *(NDEF_SUPPORT **)parg;
- if (ndef_aux == NULL)
- return 0;
-
+ if (ndef_aux == NULL)
+ return 0;
+
OPENSSL_free(ndef_aux->derbuf);
ndef_aux->derbuf = NULL;
diff --git a/contrib/libs/openssl/crypto/asn1/charmap.h b/contrib/libs/openssl/crypto/asn1/charmap.h
index 04334db38e..e234c9e615 100644
--- a/contrib/libs/openssl/crypto/asn1/charmap.h
+++ b/contrib/libs/openssl/crypto/asn1/charmap.h
@@ -2,7 +2,7 @@
* WARNING: do not edit!
* Generated by crypto/asn1/charmap.pl
*
- * Copyright 2000-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2000-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
diff --git a/contrib/libs/openssl/crypto/asn1/d2i_pr.c b/contrib/libs/openssl/crypto/asn1/d2i_pr.c
index b786236775..2094963036 100644
--- a/contrib/libs/openssl/crypto/asn1/d2i_pr.c
+++ b/contrib/libs/openssl/crypto/asn1/d2i_pr.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -56,8 +56,8 @@ EVP_PKEY *d2i_PrivateKey(int type, EVP_PKEY **a, const unsigned char **pp,
goto err;
EVP_PKEY_free(ret);
ret = tmp;
- if (EVP_PKEY_type(type) != EVP_PKEY_base_id(ret))
- goto err;
+ if (EVP_PKEY_type(type) != EVP_PKEY_base_id(ret))
+ goto err;
} else {
ASN1err(ASN1_F_D2I_PRIVATEKEY, ERR_R_ASN1_LIB);
goto err;
@@ -78,53 +78,53 @@ EVP_PKEY *d2i_PrivateKey(int type, EVP_PKEY **a, const unsigned char **pp,
* type
*/
-static EVP_PKEY *key_as_pkcs8(const unsigned char **pp, long length, int *carry_on)
-{
- const unsigned char *p = *pp;
- PKCS8_PRIV_KEY_INFO *p8 = d2i_PKCS8_PRIV_KEY_INFO(NULL, &p, length);
- EVP_PKEY *ret;
-
- if (p8 == NULL)
- return NULL;
-
- ret = EVP_PKCS82PKEY(p8);
- if (ret == NULL)
- *carry_on = 0;
-
- PKCS8_PRIV_KEY_INFO_free(p8);
-
- if (ret != NULL)
- *pp = p;
-
- return ret;
-}
-
+static EVP_PKEY *key_as_pkcs8(const unsigned char **pp, long length, int *carry_on)
+{
+ const unsigned char *p = *pp;
+ PKCS8_PRIV_KEY_INFO *p8 = d2i_PKCS8_PRIV_KEY_INFO(NULL, &p, length);
+ EVP_PKEY *ret;
+
+ if (p8 == NULL)
+ return NULL;
+
+ ret = EVP_PKCS82PKEY(p8);
+ if (ret == NULL)
+ *carry_on = 0;
+
+ PKCS8_PRIV_KEY_INFO_free(p8);
+
+ if (ret != NULL)
+ *pp = p;
+
+ return ret;
+}
+
EVP_PKEY *d2i_AutoPrivateKey(EVP_PKEY **a, const unsigned char **pp,
long length)
{
STACK_OF(ASN1_TYPE) *inkey;
const unsigned char *p;
int keytype;
- EVP_PKEY *ret = NULL;
- int carry_on = 1;
-
- ERR_set_mark();
- ret = key_as_pkcs8(pp, length, &carry_on);
- if (ret != NULL) {
- ERR_clear_last_mark();
- if (a != NULL)
- *a = ret;
- return ret;
- }
-
- if (carry_on == 0) {
- ERR_clear_last_mark();
- ASN1err(ASN1_F_D2I_AUTOPRIVATEKEY,
- ASN1_R_UNSUPPORTED_PUBLIC_KEY_TYPE);
- return NULL;
- }
+ EVP_PKEY *ret = NULL;
+ int carry_on = 1;
+
+ ERR_set_mark();
+ ret = key_as_pkcs8(pp, length, &carry_on);
+ if (ret != NULL) {
+ ERR_clear_last_mark();
+ if (a != NULL)
+ *a = ret;
+ return ret;
+ }
+
+ if (carry_on == 0) {
+ ERR_clear_last_mark();
+ ASN1err(ASN1_F_D2I_AUTOPRIVATEKEY,
+ ASN1_R_UNSUPPORTED_PUBLIC_KEY_TYPE);
+ return NULL;
+ }
p = *pp;
-
+
/*
* Dirty trick: read in the ASN1 data into a STACK_OF(ASN1_TYPE): by
* analyzing it we can determine the passed structure: this assumes the
@@ -140,15 +140,15 @@ EVP_PKEY *d2i_AutoPrivateKey(EVP_PKEY **a, const unsigned char **pp,
keytype = EVP_PKEY_DSA;
else if (sk_ASN1_TYPE_num(inkey) == 4)
keytype = EVP_PKEY_EC;
- else
+ else
keytype = EVP_PKEY_RSA;
sk_ASN1_TYPE_pop_free(inkey, ASN1_TYPE_free);
-
- ret = d2i_PrivateKey(keytype, a, pp, length);
- if (ret != NULL)
- ERR_pop_to_mark();
- else
- ERR_clear_last_mark();
-
- return ret;
+
+ ret = d2i_PrivateKey(keytype, a, pp, length);
+ if (ret != NULL)
+ ERR_pop_to_mark();
+ else
+ ERR_clear_last_mark();
+
+ return ret;
}
diff --git a/contrib/libs/openssl/crypto/asn1/t_spki.c b/contrib/libs/openssl/crypto/asn1/t_spki.c
index 5d60a6c0d3..3d4aea8ad9 100644
--- a/contrib/libs/openssl/crypto/asn1/t_spki.c
+++ b/contrib/libs/openssl/crypto/asn1/t_spki.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -38,7 +38,7 @@ int NETSCAPE_SPKI_print(BIO *out, NETSCAPE_SPKI *spki)
}
chal = spki->spkac->challenge;
if (chal->length)
- BIO_printf(out, " Challenge String: %.*s\n", chal->length, chal->data);
+ BIO_printf(out, " Challenge String: %.*s\n", chal->length, chal->data);
i = OBJ_obj2nid(spki->sig_algor.algorithm);
BIO_printf(out, " Signature Algorithm: %s",
(i == NID_undef) ? "UNKNOWN" : OBJ_nid2ln(i));
diff --git a/contrib/libs/openssl/crypto/asn1/tasn_dec.c b/contrib/libs/openssl/crypto/asn1/tasn_dec.c
index d304bc95a6..82577b1ede 100644
--- a/contrib/libs/openssl/crypto/asn1/tasn_dec.c
+++ b/contrib/libs/openssl/crypto/asn1/tasn_dec.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2000-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2000-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -182,15 +182,15 @@ static int asn1_item_embed_d2i(ASN1_VALUE **pval, const unsigned char **in,
tag, aclass, opt, ctx);
case ASN1_ITYPE_MSTRING:
- /*
- * It never makes sense for multi-strings to have implicit tagging, so
- * if tag != -1, then this looks like an error in the template.
- */
- if (tag != -1) {
- ASN1err(ASN1_F_ASN1_ITEM_EMBED_D2I, ASN1_R_BAD_TEMPLATE);
- goto err;
- }
-
+ /*
+ * It never makes sense for multi-strings to have implicit tagging, so
+ * if tag != -1, then this looks like an error in the template.
+ */
+ if (tag != -1) {
+ ASN1err(ASN1_F_ASN1_ITEM_EMBED_D2I, ASN1_R_BAD_TEMPLATE);
+ goto err;
+ }
+
p = *in;
/* Just read in tag and class */
ret = asn1_check_tlen(NULL, &otag, &oclass, NULL, NULL,
@@ -208,7 +208,7 @@ static int asn1_item_embed_d2i(ASN1_VALUE **pval, const unsigned char **in,
ASN1err(ASN1_F_ASN1_ITEM_EMBED_D2I, ASN1_R_MSTRING_NOT_UNIVERSAL);
goto err;
}
-
+
/* Check tag matches bit map */
if (!(ASN1_tag2bit(otag) & it->utype)) {
/* If OPTIONAL, assume this is OK */
@@ -225,15 +225,15 @@ static int asn1_item_embed_d2i(ASN1_VALUE **pval, const unsigned char **in,
return ef->asn1_ex_d2i(pval, in, len, it, tag, aclass, opt, ctx);
case ASN1_ITYPE_CHOICE:
- /*
- * It never makes sense for CHOICE types to have implicit tagging, so
- * if tag != -1, then this looks like an error in the template.
- */
- if (tag != -1) {
- ASN1err(ASN1_F_ASN1_ITEM_EMBED_D2I, ASN1_R_BAD_TEMPLATE);
- goto err;
- }
-
+ /*
+ * It never makes sense for CHOICE types to have implicit tagging, so
+ * if tag != -1, then this looks like an error in the template.
+ */
+ if (tag != -1) {
+ ASN1err(ASN1_F_ASN1_ITEM_EMBED_D2I, ASN1_R_BAD_TEMPLATE);
+ goto err;
+ }
+
if (asn1_cb && !asn1_cb(ASN1_OP_D2I_PRE, pval, it, NULL))
goto auxerr;
if (*pval) {
diff --git a/contrib/libs/openssl/crypto/asn1/tasn_enc.c b/contrib/libs/openssl/crypto/asn1/tasn_enc.c
index 887e60f767..bcc96337bc 100644
--- a/contrib/libs/openssl/crypto/asn1/tasn_enc.c
+++ b/contrib/libs/openssl/crypto/asn1/tasn_enc.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2000-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2000-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -103,25 +103,25 @@ int ASN1_item_ex_i2d(ASN1_VALUE **pval, unsigned char **out,
return asn1_i2d_ex_primitive(pval, out, it, tag, aclass);
case ASN1_ITYPE_MSTRING:
- /*
- * It never makes sense for multi-strings to have implicit tagging, so
- * if tag != -1, then this looks like an error in the template.
- */
- if (tag != -1) {
- ASN1err(ASN1_F_ASN1_ITEM_EX_I2D, ASN1_R_BAD_TEMPLATE);
- return -1;
- }
+ /*
+ * It never makes sense for multi-strings to have implicit tagging, so
+ * if tag != -1, then this looks like an error in the template.
+ */
+ if (tag != -1) {
+ ASN1err(ASN1_F_ASN1_ITEM_EX_I2D, ASN1_R_BAD_TEMPLATE);
+ return -1;
+ }
return asn1_i2d_ex_primitive(pval, out, it, -1, aclass);
case ASN1_ITYPE_CHOICE:
- /*
- * It never makes sense for CHOICE types to have implicit tagging, so
- * if tag != -1, then this looks like an error in the template.
- */
- if (tag != -1) {
- ASN1err(ASN1_F_ASN1_ITEM_EX_I2D, ASN1_R_BAD_TEMPLATE);
- return -1;
- }
+ /*
+ * It never makes sense for CHOICE types to have implicit tagging, so
+ * if tag != -1, then this looks like an error in the template.
+ */
+ if (tag != -1) {
+ ASN1err(ASN1_F_ASN1_ITEM_EX_I2D, ASN1_R_BAD_TEMPLATE);
+ return -1;
+ }
if (asn1_cb && !asn1_cb(ASN1_OP_I2D_PRE, pval, it, NULL))
return 0;
i = asn1_get_choice_selector(pval, it);
diff --git a/contrib/libs/openssl/crypto/asn1/x_algor.c b/contrib/libs/openssl/crypto/asn1/x_algor.c
index 39018a9f20..c9a8f1e9d1 100644
--- a/contrib/libs/openssl/crypto/asn1/x_algor.c
+++ b/contrib/libs/openssl/crypto/asn1/x_algor.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1998-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1998-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -92,35 +92,35 @@ int X509_ALGOR_cmp(const X509_ALGOR *a, const X509_ALGOR *b)
return 0;
return ASN1_TYPE_cmp(a->parameter, b->parameter);
}
-
-int X509_ALGOR_copy(X509_ALGOR *dest, const X509_ALGOR *src)
-{
- if (src == NULL || dest == NULL)
- return 0;
-
- if (dest->algorithm)
- ASN1_OBJECT_free(dest->algorithm);
- dest->algorithm = NULL;
-
- if (dest->parameter)
- ASN1_TYPE_free(dest->parameter);
- dest->parameter = NULL;
-
- if (src->algorithm)
- if ((dest->algorithm = OBJ_dup(src->algorithm)) == NULL)
- return 0;
-
- if (src->parameter) {
- dest->parameter = ASN1_TYPE_new();
- if (dest->parameter == NULL)
- return 0;
-
- /* Assuming this is also correct for a BOOL.
- * set does copy as a side effect.
- */
- if (ASN1_TYPE_set1(dest->parameter,
- src->parameter->type, src->parameter->value.ptr) == 0)
- return 0;
- }
- return 1;
-}
+
+int X509_ALGOR_copy(X509_ALGOR *dest, const X509_ALGOR *src)
+{
+ if (src == NULL || dest == NULL)
+ return 0;
+
+ if (dest->algorithm)
+ ASN1_OBJECT_free(dest->algorithm);
+ dest->algorithm = NULL;
+
+ if (dest->parameter)
+ ASN1_TYPE_free(dest->parameter);
+ dest->parameter = NULL;
+
+ if (src->algorithm)
+ if ((dest->algorithm = OBJ_dup(src->algorithm)) == NULL)
+ return 0;
+
+ if (src->parameter) {
+ dest->parameter = ASN1_TYPE_new();
+ if (dest->parameter == NULL)
+ return 0;
+
+ /* Assuming this is also correct for a BOOL.
+ * set does copy as a side effect.
+ */
+ if (ASN1_TYPE_set1(dest->parameter,
+ src->parameter->type, src->parameter->value.ptr) == 0)
+ return 0;
+ }
+ return 1;
+}
diff --git a/contrib/libs/openssl/crypto/bio/b_addr.c b/contrib/libs/openssl/crypto/bio/b_addr.c
index 07af6a77e8..8ea32bce40 100644
--- a/contrib/libs/openssl/crypto/bio/b_addr.c
+++ b/contrib/libs/openssl/crypto/bio/b_addr.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2016-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2016-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -7,10 +7,10 @@
* https://www.openssl.org/source/license.html
*/
-#ifndef _GNU_SOURCE
-# define _GNU_SOURCE
-#endif
-
+#ifndef _GNU_SOURCE
+# define _GNU_SOURCE
+#endif
+
#include <assert.h>
#include <string.h>
@@ -689,7 +689,7 @@ int BIO_lookup_ex(const char *host, const char *service, int lookup_type,
hints.ai_protocol = protocol;
# ifdef AI_ADDRCONFIG
# ifdef AF_UNSPEC
- if (host != NULL && family == AF_UNSPEC)
+ if (host != NULL && family == AF_UNSPEC)
# endif
hints.ai_flags |= AI_ADDRCONFIG;
# endif
diff --git a/contrib/libs/openssl/crypto/bio/b_print.c b/contrib/libs/openssl/crypto/bio/b_print.c
index af858d5f7f..41b7f5e2f6 100644
--- a/contrib/libs/openssl/crypto/bio/b_print.c
+++ b/contrib/libs/openssl/crypto/bio/b_print.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -635,11 +635,11 @@ fmtfp(char **sbuffer,
fvalue = tmpvalue;
}
ufvalue = abs_val(fvalue);
- /*
- * By subtracting 65535 (2^16-1) we cancel the low order 15 bits
- * of ULONG_MAX to avoid using imprecise floating point values.
- */
- if (ufvalue >= (double)(ULONG_MAX - 65535) + 65536.0) {
+ /*
+ * By subtracting 65535 (2^16-1) we cancel the low order 15 bits
+ * of ULONG_MAX to avoid using imprecise floating point values.
+ */
+ if (ufvalue >= (double)(ULONG_MAX - 65535) + 65536.0) {
/* Number too big */
return 0;
}
diff --git a/contrib/libs/openssl/crypto/bio/b_sock2.c b/contrib/libs/openssl/crypto/bio/b_sock2.c
index 7eddb6a14a..104ff31b0d 100644
--- a/contrib/libs/openssl/crypto/bio/b_sock2.c
+++ b/contrib/libs/openssl/crypto/bio/b_sock2.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2016-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2016-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -243,8 +243,8 @@ int BIO_listen(int sock, const BIO_ADDR *addr, int options)
}
}
- /* On OpenBSD it is always ipv6 only with ipv6 sockets thus read-only */
-# if defined(IPV6_V6ONLY) && !defined(__OpenBSD__)
+ /* On OpenBSD it is always ipv6 only with ipv6 sockets thus read-only */
+# if defined(IPV6_V6ONLY) && !defined(__OpenBSD__)
if (BIO_ADDR_family(addr) == AF_INET6) {
/*
* Note: Windows default of IPV6_V6ONLY is ON, and Linux is OFF.
diff --git a/contrib/libs/openssl/crypto/bio/bss_acpt.c b/contrib/libs/openssl/crypto/bio/bss_acpt.c
index ffa751470e..4461eae233 100644
--- a/contrib/libs/openssl/crypto/bio/bss_acpt.c
+++ b/contrib/libs/openssl/crypto/bio/bss_acpt.c
@@ -434,10 +434,10 @@ static long acpt_ctrl(BIO *b, int cmd, long num, void *ptr)
b->init = 1;
} else if (num == 1) {
OPENSSL_free(data->param_serv);
- if ((data->param_serv = OPENSSL_strdup(ptr)) == NULL)
- ret = 0;
- else
- b->init = 1;
+ if ((data->param_serv = OPENSSL_strdup(ptr)) == NULL)
+ ret = 0;
+ else
+ b->init = 1;
} else if (num == 2) {
data->bind_mode |= BIO_SOCK_NONBLOCK;
} else if (num == 3) {
diff --git a/contrib/libs/openssl/crypto/bio/bss_conn.c b/contrib/libs/openssl/crypto/bio/bss_conn.c
index 35acd8f36e..807a82b23b 100644
--- a/contrib/libs/openssl/crypto/bio/bss_conn.c
+++ b/contrib/libs/openssl/crypto/bio/bss_conn.c
@@ -186,17 +186,17 @@ static int conn_state(BIO *b, BIO_CONNECT *c)
case BIO_CONN_S_BLOCKED_CONNECT:
i = BIO_sock_error(b->num);
- if (i != 0) {
+ if (i != 0) {
BIO_clear_retry_flags(b);
- if ((c->addr_iter = BIO_ADDRINFO_next(c->addr_iter)) != NULL) {
- /*
- * if there are more addresses to try, do that first
- */
- BIO_closesocket(b->num);
- c->state = BIO_CONN_S_CREATE_SOCKET;
- ERR_clear_error();
- break;
- }
+ if ((c->addr_iter = BIO_ADDRINFO_next(c->addr_iter)) != NULL) {
+ /*
+ * if there are more addresses to try, do that first
+ */
+ BIO_closesocket(b->num);
+ c->state = BIO_CONN_S_CREATE_SOCKET;
+ ERR_clear_error();
+ break;
+ }
SYSerr(SYS_F_CONNECT, i);
ERR_add_error_data(4,
"hostname=", c->param_hostname,
@@ -416,13 +416,13 @@ static long conn_ctrl(BIO *b, int cmd, long num, void *ptr)
case BIO_C_SET_CONNECT:
if (ptr != NULL) {
b->init = 1;
- if (num == 0) { /* BIO_set_conn_hostname */
+ if (num == 0) { /* BIO_set_conn_hostname */
char *hold_service = data->param_service;
/* We affect the hostname regardless. However, the input
* string might contain a host:service spec, so we must
* parse it, which might or might not affect the service
*/
-
+
OPENSSL_free(data->param_hostname);
data->param_hostname = NULL;
ret = BIO_parse_hostserv(ptr,
@@ -431,29 +431,29 @@ static long conn_ctrl(BIO *b, int cmd, long num, void *ptr)
BIO_PARSE_PRIO_HOST);
if (hold_service != data->param_service)
OPENSSL_free(hold_service);
- } else if (num == 1) { /* BIO_set_conn_port */
+ } else if (num == 1) { /* BIO_set_conn_port */
OPENSSL_free(data->param_service);
- if ((data->param_service = OPENSSL_strdup(ptr)) == NULL)
- ret = 0;
- } else if (num == 2) { /* BIO_set_conn_address */
+ if ((data->param_service = OPENSSL_strdup(ptr)) == NULL)
+ ret = 0;
+ } else if (num == 2) { /* BIO_set_conn_address */
const BIO_ADDR *addr = (const BIO_ADDR *)ptr;
- char *host = BIO_ADDR_hostname_string(addr, 1);
- char *service = BIO_ADDR_service_string(addr, 1);
-
- ret = host != NULL && service != NULL;
+ char *host = BIO_ADDR_hostname_string(addr, 1);
+ char *service = BIO_ADDR_service_string(addr, 1);
+
+ ret = host != NULL && service != NULL;
if (ret) {
- OPENSSL_free(data->param_hostname);
- data->param_hostname = host;
- OPENSSL_free(data->param_service);
- data->param_service = service;
+ OPENSSL_free(data->param_hostname);
+ data->param_hostname = host;
+ OPENSSL_free(data->param_service);
+ data->param_service = service;
BIO_ADDRINFO_free(data->addr_first);
data->addr_first = NULL;
data->addr_iter = NULL;
- } else {
- OPENSSL_free(host);
- OPENSSL_free(service);
+ } else {
+ OPENSSL_free(host);
+ OPENSSL_free(service);
}
- } else if (num == 3) { /* BIO_set_conn_ip_family */
+ } else if (num == 3) { /* BIO_set_conn_ip_family */
data->connect_family = *(int *)ptr;
} else {
ret = 0;
diff --git a/contrib/libs/openssl/crypto/bn/README.pod b/contrib/libs/openssl/crypto/bn/README.pod
index f23d0311f4..5d5c4fa99f 100644
--- a/contrib/libs/openssl/crypto/bn/README.pod
+++ b/contrib/libs/openssl/crypto/bn/README.pod
@@ -1,241 +1,241 @@
-=pod
-
-=head1 NAME
-
-bn_mul_words, bn_mul_add_words, bn_sqr_words, bn_div_words,
-bn_add_words, bn_sub_words, bn_mul_comba4, bn_mul_comba8,
-bn_sqr_comba4, bn_sqr_comba8, bn_cmp_words, bn_mul_normal,
-bn_mul_low_normal, bn_mul_recursive, bn_mul_part_recursive,
-bn_mul_low_recursive, bn_sqr_normal, bn_sqr_recursive,
-bn_expand, bn_wexpand, bn_expand2, bn_fix_top, bn_check_top,
-bn_print, bn_dump, bn_set_max, bn_set_high, bn_set_low - BIGNUM
-library internal functions
-
-=head1 SYNOPSIS
-
- #include <openssl/bn.h>
-
- BN_ULONG bn_mul_words(BN_ULONG *rp, BN_ULONG *ap, int num, BN_ULONG w);
- BN_ULONG bn_mul_add_words(BN_ULONG *rp, BN_ULONG *ap, int num,
- BN_ULONG w);
- void bn_sqr_words(BN_ULONG *rp, BN_ULONG *ap, int num);
- BN_ULONG bn_div_words(BN_ULONG h, BN_ULONG l, BN_ULONG d);
- BN_ULONG bn_add_words(BN_ULONG *rp, BN_ULONG *ap, BN_ULONG *bp,
- int num);
- BN_ULONG bn_sub_words(BN_ULONG *rp, BN_ULONG *ap, BN_ULONG *bp,
- int num);
-
- void bn_mul_comba4(BN_ULONG *r, BN_ULONG *a, BN_ULONG *b);
- void bn_mul_comba8(BN_ULONG *r, BN_ULONG *a, BN_ULONG *b);
- void bn_sqr_comba4(BN_ULONG *r, BN_ULONG *a);
- void bn_sqr_comba8(BN_ULONG *r, BN_ULONG *a);
-
- int bn_cmp_words(BN_ULONG *a, BN_ULONG *b, int n);
-
- void bn_mul_normal(BN_ULONG *r, BN_ULONG *a, int na, BN_ULONG *b,
- int nb);
- void bn_mul_low_normal(BN_ULONG *r, BN_ULONG *a, BN_ULONG *b, int n);
- void bn_mul_recursive(BN_ULONG *r, BN_ULONG *a, BN_ULONG *b, int n2,
- int dna, int dnb, BN_ULONG *tmp);
- void bn_mul_part_recursive(BN_ULONG *r, BN_ULONG *a, BN_ULONG *b,
- int n, int tna, int tnb, BN_ULONG *tmp);
- void bn_mul_low_recursive(BN_ULONG *r, BN_ULONG *a, BN_ULONG *b,
- int n2, BN_ULONG *tmp);
-
- void bn_sqr_normal(BN_ULONG *r, BN_ULONG *a, int n, BN_ULONG *tmp);
- void bn_sqr_recursive(BN_ULONG *r, BN_ULONG *a, int n2, BN_ULONG *tmp);
-
- void mul(BN_ULONG r, BN_ULONG a, BN_ULONG w, BN_ULONG c);
- void mul_add(BN_ULONG r, BN_ULONG a, BN_ULONG w, BN_ULONG c);
- void sqr(BN_ULONG r0, BN_ULONG r1, BN_ULONG a);
-
- BIGNUM *bn_expand(BIGNUM *a, int bits);
- BIGNUM *bn_wexpand(BIGNUM *a, int n);
- BIGNUM *bn_expand2(BIGNUM *a, int n);
- void bn_fix_top(BIGNUM *a);
-
- void bn_check_top(BIGNUM *a);
- void bn_print(BIGNUM *a);
- void bn_dump(BN_ULONG *d, int n);
- void bn_set_max(BIGNUM *a);
- void bn_set_high(BIGNUM *r, BIGNUM *a, int n);
- void bn_set_low(BIGNUM *r, BIGNUM *a, int n);
-
-=head1 DESCRIPTION
-
-This page documents the internal functions used by the OpenSSL
-B<BIGNUM> implementation. They are described here to facilitate
-debugging and extending the library. They are I<not> to be used by
-applications.
-
-=head2 The BIGNUM structure
-
- typedef struct bignum_st BIGNUM;
-
- struct bignum_st
- {
- BN_ULONG *d; /* Pointer to an array of 'BN_BITS2' bit chunks. */
- int top; /* Index of last used d +1. */
- /* The next are internal book keeping for bn_expand. */
- int dmax; /* Size of the d array. */
- int neg; /* one if the number is negative */
- int flags;
- };
-
-
-The integer value is stored in B<d>, a malloc()ed array of words (B<BN_ULONG>),
-least significant word first. A B<BN_ULONG> can be either 16, 32 or 64 bits
-in size, depending on the 'number of bits' (B<BITS2>) specified in
-C<openssl/bn.h>.
-
-B<dmax> is the size of the B<d> array that has been allocated. B<top>
-is the number of words being used, so for a value of 4, bn.d[0]=4 and
-bn.top=1. B<neg> is 1 if the number is negative. When a B<BIGNUM> is
-B<0>, the B<d> field can be B<NULL> and B<top> == B<0>.
-
-B<flags> is a bit field of flags which are defined in C<openssl/bn.h>. The
-flags begin with B<BN_FLG_>. The macros BN_set_flags(b, n) and
-BN_get_flags(b, n) exist to enable or fetch flag(s) B<n> from B<BIGNUM>
-structure B<b>.
-
-Various routines in this library require the use of temporary
-B<BIGNUM> variables during their execution. Since dynamic memory
-allocation to create B<BIGNUM>s is rather expensive when used in
-conjunction with repeated subroutine calls, the B<BN_CTX> structure is
-used. This structure contains B<BN_CTX_NUM> B<BIGNUM>s, see
-L<BN_CTX_start(3)>.
-
-=head2 Low-level arithmetic operations
-
-These functions are implemented in C and for several platforms in
-assembly language:
-
-bn_mul_words(B<rp>, B<ap>, B<num>, B<w>) operates on the B<num> word
-arrays B<rp> and B<ap>. It computes B<ap> * B<w>, places the result
-in B<rp>, and returns the high word (carry).
-
-bn_mul_add_words(B<rp>, B<ap>, B<num>, B<w>) operates on the B<num>
-word arrays B<rp> and B<ap>. It computes B<ap> * B<w> + B<rp>, places
-the result in B<rp>, and returns the high word (carry).
-
-bn_sqr_words(B<rp>, B<ap>, B<n>) operates on the B<num> word array
-B<ap> and the 2*B<num> word array B<ap>. It computes B<ap> * B<ap>
-word-wise, and places the low and high bytes of the result in B<rp>.
-
-bn_div_words(B<h>, B<l>, B<d>) divides the two word number (B<h>, B<l>)
-by B<d> and returns the result.
-
-bn_add_words(B<rp>, B<ap>, B<bp>, B<num>) operates on the B<num> word
-arrays B<ap>, B<bp> and B<rp>. It computes B<ap> + B<bp>, places the
-result in B<rp>, and returns the high word (carry).
-
-bn_sub_words(B<rp>, B<ap>, B<bp>, B<num>) operates on the B<num> word
-arrays B<ap>, B<bp> and B<rp>. It computes B<ap> - B<bp>, places the
-result in B<rp>, and returns the carry (1 if B<bp> E<gt> B<ap>, 0
-otherwise).
-
-bn_mul_comba4(B<r>, B<a>, B<b>) operates on the 4 word arrays B<a> and
-B<b> and the 8 word array B<r>. It computes B<a>*B<b> and places the
-result in B<r>.
-
-bn_mul_comba8(B<r>, B<a>, B<b>) operates on the 8 word arrays B<a> and
-B<b> and the 16 word array B<r>. It computes B<a>*B<b> and places the
-result in B<r>.
-
-bn_sqr_comba4(B<r>, B<a>, B<b>) operates on the 4 word arrays B<a> and
-B<b> and the 8 word array B<r>.
-
-bn_sqr_comba8(B<r>, B<a>, B<b>) operates on the 8 word arrays B<a> and
-B<b> and the 16 word array B<r>.
-
-The following functions are implemented in C:
-
-bn_cmp_words(B<a>, B<b>, B<n>) operates on the B<n> word arrays B<a>
-and B<b>. It returns 1, 0 and -1 if B<a> is greater than, equal and
-less than B<b>.
-
-bn_mul_normal(B<r>, B<a>, B<na>, B<b>, B<nb>) operates on the B<na>
-word array B<a>, the B<nb> word array B<b> and the B<na>+B<nb> word
-array B<r>. It computes B<a>*B<b> and places the result in B<r>.
-
-bn_mul_low_normal(B<r>, B<a>, B<b>, B<n>) operates on the B<n> word
-arrays B<r>, B<a> and B<b>. It computes the B<n> low words of
-B<a>*B<b> and places the result in B<r>.
-
-bn_mul_recursive(B<r>, B<a>, B<b>, B<n2>, B<dna>, B<dnb>, B<t>) operates
-on the word arrays B<a> and B<b> of length B<n2>+B<dna> and B<n2>+B<dnb>
-(B<dna> and B<dnb> are currently allowed to be 0 or negative) and the 2*B<n2>
-word arrays B<r> and B<t>. B<n2> must be a power of 2. It computes
-B<a>*B<b> and places the result in B<r>.
-
-bn_mul_part_recursive(B<r>, B<a>, B<b>, B<n>, B<tna>, B<tnb>, B<tmp>)
-operates on the word arrays B<a> and B<b> of length B<n>+B<tna> and
-B<n>+B<tnb> and the 4*B<n> word arrays B<r> and B<tmp>.
-
-bn_mul_low_recursive(B<r>, B<a>, B<b>, B<n2>, B<tmp>) operates on the
-B<n2> word arrays B<r> and B<tmp> and the B<n2>/2 word arrays B<a>
-and B<b>.
-
-BN_mul() calls bn_mul_normal(), or an optimized implementation if the
-factors have the same size: bn_mul_comba8() is used if they are 8
-words long, bn_mul_recursive() if they are larger than
-B<BN_MULL_SIZE_NORMAL> and the size is an exact multiple of the word
-size, and bn_mul_part_recursive() for others that are larger than
-B<BN_MULL_SIZE_NORMAL>.
-
-bn_sqr_normal(B<r>, B<a>, B<n>, B<tmp>) operates on the B<n> word array
-B<a> and the 2*B<n> word arrays B<tmp> and B<r>.
-
-The implementations use the following macros which, depending on the
-architecture, may use "long long" C operations or inline assembler.
-They are defined in C<bn_local.h>.
-
-mul(B<r>, B<a>, B<w>, B<c>) computes B<w>*B<a>+B<c> and places the
-low word of the result in B<r> and the high word in B<c>.
-
-mul_add(B<r>, B<a>, B<w>, B<c>) computes B<w>*B<a>+B<r>+B<c> and
-places the low word of the result in B<r> and the high word in B<c>.
-
-sqr(B<r0>, B<r1>, B<a>) computes B<a>*B<a> and places the low word
-of the result in B<r0> and the high word in B<r1>.
-
-=head2 Size changes
-
-bn_expand() ensures that B<b> has enough space for a B<bits> bit
-number. bn_wexpand() ensures that B<b> has enough space for an
-B<n> word number. If the number has to be expanded, both macros
-call bn_expand2(), which allocates a new B<d> array and copies the
-data. They return B<NULL> on error, B<b> otherwise.
-
-The bn_fix_top() macro reduces B<a-E<gt>top> to point to the most
-significant non-zero word plus one when B<a> has shrunk.
-
-=head2 Debugging
-
-bn_check_top() verifies that C<((a)-E<gt>top E<gt>= 0 && (a)-E<gt>top
-E<lt>= (a)-E<gt>dmax)>. A violation will cause the program to abort.
-
-bn_print() prints B<a> to stderr. bn_dump() prints B<n> words at B<d>
-(in reverse order, i.e. most significant word first) to stderr.
-
-bn_set_max() makes B<a> a static number with a B<dmax> of its current size.
-This is used by bn_set_low() and bn_set_high() to make B<r> a read-only
-B<BIGNUM> that contains the B<n> low or high words of B<a>.
-
-If B<BN_DEBUG> is not defined, bn_check_top(), bn_print(), bn_dump()
-and bn_set_max() are defined as empty macros.
-
-=head1 SEE ALSO
-
-L<bn(3)>
-
-=head1 COPYRIGHT
-
-Copyright 2000-2016 The OpenSSL Project Authors. All Rights Reserved.
-
-Licensed under the OpenSSL license (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
-L<https://www.openssl.org/source/license.html>.
-
-=cut
+=pod
+
+=head1 NAME
+
+bn_mul_words, bn_mul_add_words, bn_sqr_words, bn_div_words,
+bn_add_words, bn_sub_words, bn_mul_comba4, bn_mul_comba8,
+bn_sqr_comba4, bn_sqr_comba8, bn_cmp_words, bn_mul_normal,
+bn_mul_low_normal, bn_mul_recursive, bn_mul_part_recursive,
+bn_mul_low_recursive, bn_sqr_normal, bn_sqr_recursive,
+bn_expand, bn_wexpand, bn_expand2, bn_fix_top, bn_check_top,
+bn_print, bn_dump, bn_set_max, bn_set_high, bn_set_low - BIGNUM
+library internal functions
+
+=head1 SYNOPSIS
+
+ #include <openssl/bn.h>
+
+ BN_ULONG bn_mul_words(BN_ULONG *rp, BN_ULONG *ap, int num, BN_ULONG w);
+ BN_ULONG bn_mul_add_words(BN_ULONG *rp, BN_ULONG *ap, int num,
+ BN_ULONG w);
+ void bn_sqr_words(BN_ULONG *rp, BN_ULONG *ap, int num);
+ BN_ULONG bn_div_words(BN_ULONG h, BN_ULONG l, BN_ULONG d);
+ BN_ULONG bn_add_words(BN_ULONG *rp, BN_ULONG *ap, BN_ULONG *bp,
+ int num);
+ BN_ULONG bn_sub_words(BN_ULONG *rp, BN_ULONG *ap, BN_ULONG *bp,
+ int num);
+
+ void bn_mul_comba4(BN_ULONG *r, BN_ULONG *a, BN_ULONG *b);
+ void bn_mul_comba8(BN_ULONG *r, BN_ULONG *a, BN_ULONG *b);
+ void bn_sqr_comba4(BN_ULONG *r, BN_ULONG *a);
+ void bn_sqr_comba8(BN_ULONG *r, BN_ULONG *a);
+
+ int bn_cmp_words(BN_ULONG *a, BN_ULONG *b, int n);
+
+ void bn_mul_normal(BN_ULONG *r, BN_ULONG *a, int na, BN_ULONG *b,
+ int nb);
+ void bn_mul_low_normal(BN_ULONG *r, BN_ULONG *a, BN_ULONG *b, int n);
+ void bn_mul_recursive(BN_ULONG *r, BN_ULONG *a, BN_ULONG *b, int n2,
+ int dna, int dnb, BN_ULONG *tmp);
+ void bn_mul_part_recursive(BN_ULONG *r, BN_ULONG *a, BN_ULONG *b,
+ int n, int tna, int tnb, BN_ULONG *tmp);
+ void bn_mul_low_recursive(BN_ULONG *r, BN_ULONG *a, BN_ULONG *b,
+ int n2, BN_ULONG *tmp);
+
+ void bn_sqr_normal(BN_ULONG *r, BN_ULONG *a, int n, BN_ULONG *tmp);
+ void bn_sqr_recursive(BN_ULONG *r, BN_ULONG *a, int n2, BN_ULONG *tmp);
+
+ void mul(BN_ULONG r, BN_ULONG a, BN_ULONG w, BN_ULONG c);
+ void mul_add(BN_ULONG r, BN_ULONG a, BN_ULONG w, BN_ULONG c);
+ void sqr(BN_ULONG r0, BN_ULONG r1, BN_ULONG a);
+
+ BIGNUM *bn_expand(BIGNUM *a, int bits);
+ BIGNUM *bn_wexpand(BIGNUM *a, int n);
+ BIGNUM *bn_expand2(BIGNUM *a, int n);
+ void bn_fix_top(BIGNUM *a);
+
+ void bn_check_top(BIGNUM *a);
+ void bn_print(BIGNUM *a);
+ void bn_dump(BN_ULONG *d, int n);
+ void bn_set_max(BIGNUM *a);
+ void bn_set_high(BIGNUM *r, BIGNUM *a, int n);
+ void bn_set_low(BIGNUM *r, BIGNUM *a, int n);
+
+=head1 DESCRIPTION
+
+This page documents the internal functions used by the OpenSSL
+B<BIGNUM> implementation. They are described here to facilitate
+debugging and extending the library. They are I<not> to be used by
+applications.
+
+=head2 The BIGNUM structure
+
+ typedef struct bignum_st BIGNUM;
+
+ struct bignum_st
+ {
+ BN_ULONG *d; /* Pointer to an array of 'BN_BITS2' bit chunks. */
+ int top; /* Index of last used d +1. */
+ /* The next are internal book keeping for bn_expand. */
+ int dmax; /* Size of the d array. */
+ int neg; /* one if the number is negative */
+ int flags;
+ };
+
+
+The integer value is stored in B<d>, a malloc()ed array of words (B<BN_ULONG>),
+least significant word first. A B<BN_ULONG> can be either 16, 32 or 64 bits
+in size, depending on the 'number of bits' (B<BITS2>) specified in
+C<openssl/bn.h>.
+
+B<dmax> is the size of the B<d> array that has been allocated. B<top>
+is the number of words being used, so for a value of 4, bn.d[0]=4 and
+bn.top=1. B<neg> is 1 if the number is negative. When a B<BIGNUM> is
+B<0>, the B<d> field can be B<NULL> and B<top> == B<0>.
+
+B<flags> is a bit field of flags which are defined in C<openssl/bn.h>. The
+flags begin with B<BN_FLG_>. The macros BN_set_flags(b, n) and
+BN_get_flags(b, n) exist to enable or fetch flag(s) B<n> from B<BIGNUM>
+structure B<b>.
+
+Various routines in this library require the use of temporary
+B<BIGNUM> variables during their execution. Since dynamic memory
+allocation to create B<BIGNUM>s is rather expensive when used in
+conjunction with repeated subroutine calls, the B<BN_CTX> structure is
+used. This structure contains B<BN_CTX_NUM> B<BIGNUM>s, see
+L<BN_CTX_start(3)>.
+
+=head2 Low-level arithmetic operations
+
+These functions are implemented in C and for several platforms in
+assembly language:
+
+bn_mul_words(B<rp>, B<ap>, B<num>, B<w>) operates on the B<num> word
+arrays B<rp> and B<ap>. It computes B<ap> * B<w>, places the result
+in B<rp>, and returns the high word (carry).
+
+bn_mul_add_words(B<rp>, B<ap>, B<num>, B<w>) operates on the B<num>
+word arrays B<rp> and B<ap>. It computes B<ap> * B<w> + B<rp>, places
+the result in B<rp>, and returns the high word (carry).
+
+bn_sqr_words(B<rp>, B<ap>, B<n>) operates on the B<num> word array
+B<ap> and the 2*B<num> word array B<ap>. It computes B<ap> * B<ap>
+word-wise, and places the low and high bytes of the result in B<rp>.
+
+bn_div_words(B<h>, B<l>, B<d>) divides the two word number (B<h>, B<l>)
+by B<d> and returns the result.
+
+bn_add_words(B<rp>, B<ap>, B<bp>, B<num>) operates on the B<num> word
+arrays B<ap>, B<bp> and B<rp>. It computes B<ap> + B<bp>, places the
+result in B<rp>, and returns the high word (carry).
+
+bn_sub_words(B<rp>, B<ap>, B<bp>, B<num>) operates on the B<num> word
+arrays B<ap>, B<bp> and B<rp>. It computes B<ap> - B<bp>, places the
+result in B<rp>, and returns the carry (1 if B<bp> E<gt> B<ap>, 0
+otherwise).
+
+bn_mul_comba4(B<r>, B<a>, B<b>) operates on the 4 word arrays B<a> and
+B<b> and the 8 word array B<r>. It computes B<a>*B<b> and places the
+result in B<r>.
+
+bn_mul_comba8(B<r>, B<a>, B<b>) operates on the 8 word arrays B<a> and
+B<b> and the 16 word array B<r>. It computes B<a>*B<b> and places the
+result in B<r>.
+
+bn_sqr_comba4(B<r>, B<a>, B<b>) operates on the 4 word arrays B<a> and
+B<b> and the 8 word array B<r>.
+
+bn_sqr_comba8(B<r>, B<a>, B<b>) operates on the 8 word arrays B<a> and
+B<b> and the 16 word array B<r>.
+
+The following functions are implemented in C:
+
+bn_cmp_words(B<a>, B<b>, B<n>) operates on the B<n> word arrays B<a>
+and B<b>. It returns 1, 0 and -1 if B<a> is greater than, equal and
+less than B<b>.
+
+bn_mul_normal(B<r>, B<a>, B<na>, B<b>, B<nb>) operates on the B<na>
+word array B<a>, the B<nb> word array B<b> and the B<na>+B<nb> word
+array B<r>. It computes B<a>*B<b> and places the result in B<r>.
+
+bn_mul_low_normal(B<r>, B<a>, B<b>, B<n>) operates on the B<n> word
+arrays B<r>, B<a> and B<b>. It computes the B<n> low words of
+B<a>*B<b> and places the result in B<r>.
+
+bn_mul_recursive(B<r>, B<a>, B<b>, B<n2>, B<dna>, B<dnb>, B<t>) operates
+on the word arrays B<a> and B<b> of length B<n2>+B<dna> and B<n2>+B<dnb>
+(B<dna> and B<dnb> are currently allowed to be 0 or negative) and the 2*B<n2>
+word arrays B<r> and B<t>. B<n2> must be a power of 2. It computes
+B<a>*B<b> and places the result in B<r>.
+
+bn_mul_part_recursive(B<r>, B<a>, B<b>, B<n>, B<tna>, B<tnb>, B<tmp>)
+operates on the word arrays B<a> and B<b> of length B<n>+B<tna> and
+B<n>+B<tnb> and the 4*B<n> word arrays B<r> and B<tmp>.
+
+bn_mul_low_recursive(B<r>, B<a>, B<b>, B<n2>, B<tmp>) operates on the
+B<n2> word arrays B<r> and B<tmp> and the B<n2>/2 word arrays B<a>
+and B<b>.
+
+BN_mul() calls bn_mul_normal(), or an optimized implementation if the
+factors have the same size: bn_mul_comba8() is used if they are 8
+words long, bn_mul_recursive() if they are larger than
+B<BN_MULL_SIZE_NORMAL> and the size is an exact multiple of the word
+size, and bn_mul_part_recursive() for others that are larger than
+B<BN_MULL_SIZE_NORMAL>.
+
+bn_sqr_normal(B<r>, B<a>, B<n>, B<tmp>) operates on the B<n> word array
+B<a> and the 2*B<n> word arrays B<tmp> and B<r>.
+
+The implementations use the following macros which, depending on the
+architecture, may use "long long" C operations or inline assembler.
+They are defined in C<bn_local.h>.
+
+mul(B<r>, B<a>, B<w>, B<c>) computes B<w>*B<a>+B<c> and places the
+low word of the result in B<r> and the high word in B<c>.
+
+mul_add(B<r>, B<a>, B<w>, B<c>) computes B<w>*B<a>+B<r>+B<c> and
+places the low word of the result in B<r> and the high word in B<c>.
+
+sqr(B<r0>, B<r1>, B<a>) computes B<a>*B<a> and places the low word
+of the result in B<r0> and the high word in B<r1>.
+
+=head2 Size changes
+
+bn_expand() ensures that B<b> has enough space for a B<bits> bit
+number. bn_wexpand() ensures that B<b> has enough space for an
+B<n> word number. If the number has to be expanded, both macros
+call bn_expand2(), which allocates a new B<d> array and copies the
+data. They return B<NULL> on error, B<b> otherwise.
+
+The bn_fix_top() macro reduces B<a-E<gt>top> to point to the most
+significant non-zero word plus one when B<a> has shrunk.
+
+=head2 Debugging
+
+bn_check_top() verifies that C<((a)-E<gt>top E<gt>= 0 && (a)-E<gt>top
+E<lt>= (a)-E<gt>dmax)>. A violation will cause the program to abort.
+
+bn_print() prints B<a> to stderr. bn_dump() prints B<n> words at B<d>
+(in reverse order, i.e. most significant word first) to stderr.
+
+bn_set_max() makes B<a> a static number with a B<dmax> of its current size.
+This is used by bn_set_low() and bn_set_high() to make B<r> a read-only
+B<BIGNUM> that contains the B<n> low or high words of B<a>.
+
+If B<BN_DEBUG> is not defined, bn_check_top(), bn_print(), bn_dump()
+and bn_set_max() are defined as empty macros.
+
+=head1 SEE ALSO
+
+L<bn(3)>
+
+=head1 COPYRIGHT
+
+Copyright 2000-2016 The OpenSSL Project Authors. All Rights Reserved.
+
+Licensed under the OpenSSL license (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
+L<https://www.openssl.org/source/license.html>.
+
+=cut
diff --git a/contrib/libs/openssl/crypto/bn/bn_div.c b/contrib/libs/openssl/crypto/bn/bn_div.c
index 2c3e03044e..0da9f39b31 100644
--- a/contrib/libs/openssl/crypto/bn/bn_div.c
+++ b/contrib/libs/openssl/crypto/bn/bn_div.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -268,7 +268,7 @@ int bn_div_fixed_top(BIGNUM *dv, BIGNUM *rm, const BIGNUM *num,
BIGNUM *tmp, *snum, *sdiv, *res;
BN_ULONG *resp, *wnum, *wnumtop;
BN_ULONG d0, d1;
- int num_n, div_n, num_neg;
+ int num_n, div_n, num_neg;
assert(divisor->top > 0 && divisor->d[divisor->top - 1] != 0);
@@ -326,8 +326,8 @@ int bn_div_fixed_top(BIGNUM *dv, BIGNUM *rm, const BIGNUM *num,
/* Setup quotient */
if (!bn_wexpand(res, loop))
goto err;
- num_neg = num->neg;
- res->neg = (num_neg ^ divisor->neg);
+ num_neg = num->neg;
+ res->neg = (num_neg ^ divisor->neg);
res->top = loop;
res->flags |= BN_FLG_FIXED_TOP;
resp = &(res->d[loop]);
@@ -443,7 +443,7 @@ int bn_div_fixed_top(BIGNUM *dv, BIGNUM *rm, const BIGNUM *num,
*--resp = q;
}
/* snum holds remainder, it's as wide as divisor */
- snum->neg = num_neg;
+ snum->neg = num_neg;
snum->top = div_n;
snum->flags |= BN_FLG_FIXED_TOP;
if (rm != NULL)
diff --git a/contrib/libs/openssl/crypto/bn/bn_gcd.c b/contrib/libs/openssl/crypto/bn/bn_gcd.c
index cdb957d6bc..0941f7b97f 100644
--- a/contrib/libs/openssl/crypto/bn/bn_gcd.c
+++ b/contrib/libs/openssl/crypto/bn/bn_gcd.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -10,189 +10,189 @@
#include "internal/cryptlib.h"
#include "bn_local.h"
-/*
- * bn_mod_inverse_no_branch is a special version of BN_mod_inverse. It does
- * not contain branches that may leak sensitive information.
- *
- * This is a static function, we ensure all callers in this file pass valid
- * arguments: all passed pointers here are non-NULL.
- */
-static ossl_inline
-BIGNUM *bn_mod_inverse_no_branch(BIGNUM *in,
- const BIGNUM *a, const BIGNUM *n,
- BN_CTX *ctx, int *pnoinv)
-{
- BIGNUM *A, *B, *X, *Y, *M, *D, *T, *R = NULL;
- BIGNUM *ret = NULL;
- int sign;
-
- bn_check_top(a);
- bn_check_top(n);
-
- BN_CTX_start(ctx);
- A = BN_CTX_get(ctx);
- B = BN_CTX_get(ctx);
- X = BN_CTX_get(ctx);
- D = BN_CTX_get(ctx);
- M = BN_CTX_get(ctx);
- Y = BN_CTX_get(ctx);
- T = BN_CTX_get(ctx);
- if (T == NULL)
- goto err;
-
- if (in == NULL)
- R = BN_new();
- else
- R = in;
- if (R == NULL)
- goto err;
-
- BN_one(X);
- BN_zero(Y);
- if (BN_copy(B, a) == NULL)
- goto err;
- if (BN_copy(A, n) == NULL)
- goto err;
- A->neg = 0;
-
- if (B->neg || (BN_ucmp(B, A) >= 0)) {
- /*
- * Turn BN_FLG_CONSTTIME flag on, so that when BN_div is invoked,
- * BN_div_no_branch will be called eventually.
- */
- {
- BIGNUM local_B;
- bn_init(&local_B);
- BN_with_flags(&local_B, B, BN_FLG_CONSTTIME);
- if (!BN_nnmod(B, &local_B, A, ctx))
- goto err;
- /* Ensure local_B goes out of scope before any further use of B */
- }
- }
- sign = -1;
- /*-
- * From B = a mod |n|, A = |n| it follows that
- *
- * 0 <= B < A,
- * -sign*X*a == B (mod |n|),
- * sign*Y*a == A (mod |n|).
- */
-
- while (!BN_is_zero(B)) {
- BIGNUM *tmp;
-
- /*-
- * 0 < B < A,
- * (*) -sign*X*a == B (mod |n|),
- * sign*Y*a == A (mod |n|)
- */
-
- /*
- * Turn BN_FLG_CONSTTIME flag on, so that when BN_div is invoked,
- * BN_div_no_branch will be called eventually.
- */
- {
- BIGNUM local_A;
- bn_init(&local_A);
- BN_with_flags(&local_A, A, BN_FLG_CONSTTIME);
-
- /* (D, M) := (A/B, A%B) ... */
- if (!BN_div(D, M, &local_A, B, ctx))
- goto err;
- /* Ensure local_A goes out of scope before any further use of A */
- }
-
- /*-
- * Now
- * A = D*B + M;
- * thus we have
- * (**) sign*Y*a == D*B + M (mod |n|).
- */
-
- tmp = A; /* keep the BIGNUM object, the value does not
- * matter */
-
- /* (A, B) := (B, A mod B) ... */
- A = B;
- B = M;
- /* ... so we have 0 <= B < A again */
-
- /*-
- * Since the former M is now B and the former B is now A,
- * (**) translates into
- * sign*Y*a == D*A + B (mod |n|),
- * i.e.
- * sign*Y*a - D*A == B (mod |n|).
- * Similarly, (*) translates into
- * -sign*X*a == A (mod |n|).
- *
- * Thus,
- * sign*Y*a + D*sign*X*a == B (mod |n|),
- * i.e.
- * sign*(Y + D*X)*a == B (mod |n|).
- *
- * So if we set (X, Y, sign) := (Y + D*X, X, -sign), we arrive back at
- * -sign*X*a == B (mod |n|),
- * sign*Y*a == A (mod |n|).
- * Note that X and Y stay non-negative all the time.
- */
-
- if (!BN_mul(tmp, D, X, ctx))
- goto err;
- if (!BN_add(tmp, tmp, Y))
- goto err;
-
- M = Y; /* keep the BIGNUM object, the value does not
- * matter */
- Y = X;
- X = tmp;
- sign = -sign;
- }
-
- /*-
- * The while loop (Euclid's algorithm) ends when
- * A == gcd(a,n);
- * we have
- * sign*Y*a == A (mod |n|),
- * where Y is non-negative.
- */
-
- if (sign < 0) {
- if (!BN_sub(Y, n, Y))
- goto err;
- }
- /* Now Y*a == A (mod |n|). */
-
- if (BN_is_one(A)) {
- /* Y*a == 1 (mod |n|) */
- if (!Y->neg && BN_ucmp(Y, n) < 0) {
- if (!BN_copy(R, Y))
- goto err;
- } else {
- if (!BN_nnmod(R, Y, n, ctx))
- goto err;
- }
- } else {
- *pnoinv = 1;
- /* caller sets the BN_R_NO_INVERSE error */
- goto err;
- }
-
- ret = R;
- *pnoinv = 0;
-
- err:
- if ((ret == NULL) && (in == NULL))
- BN_free(R);
- BN_CTX_end(ctx);
- bn_check_top(ret);
- return ret;
+/*
+ * bn_mod_inverse_no_branch is a special version of BN_mod_inverse. It does
+ * not contain branches that may leak sensitive information.
+ *
+ * This is a static function, we ensure all callers in this file pass valid
+ * arguments: all passed pointers here are non-NULL.
+ */
+static ossl_inline
+BIGNUM *bn_mod_inverse_no_branch(BIGNUM *in,
+ const BIGNUM *a, const BIGNUM *n,
+ BN_CTX *ctx, int *pnoinv)
+{
+ BIGNUM *A, *B, *X, *Y, *M, *D, *T, *R = NULL;
+ BIGNUM *ret = NULL;
+ int sign;
+
+ bn_check_top(a);
+ bn_check_top(n);
+
+ BN_CTX_start(ctx);
+ A = BN_CTX_get(ctx);
+ B = BN_CTX_get(ctx);
+ X = BN_CTX_get(ctx);
+ D = BN_CTX_get(ctx);
+ M = BN_CTX_get(ctx);
+ Y = BN_CTX_get(ctx);
+ T = BN_CTX_get(ctx);
+ if (T == NULL)
+ goto err;
+
+ if (in == NULL)
+ R = BN_new();
+ else
+ R = in;
+ if (R == NULL)
+ goto err;
+
+ BN_one(X);
+ BN_zero(Y);
+ if (BN_copy(B, a) == NULL)
+ goto err;
+ if (BN_copy(A, n) == NULL)
+ goto err;
+ A->neg = 0;
+
+ if (B->neg || (BN_ucmp(B, A) >= 0)) {
+ /*
+ * Turn BN_FLG_CONSTTIME flag on, so that when BN_div is invoked,
+ * BN_div_no_branch will be called eventually.
+ */
+ {
+ BIGNUM local_B;
+ bn_init(&local_B);
+ BN_with_flags(&local_B, B, BN_FLG_CONSTTIME);
+ if (!BN_nnmod(B, &local_B, A, ctx))
+ goto err;
+ /* Ensure local_B goes out of scope before any further use of B */
+ }
+ }
+ sign = -1;
+ /*-
+ * From B = a mod |n|, A = |n| it follows that
+ *
+ * 0 <= B < A,
+ * -sign*X*a == B (mod |n|),
+ * sign*Y*a == A (mod |n|).
+ */
+
+ while (!BN_is_zero(B)) {
+ BIGNUM *tmp;
+
+ /*-
+ * 0 < B < A,
+ * (*) -sign*X*a == B (mod |n|),
+ * sign*Y*a == A (mod |n|)
+ */
+
+ /*
+ * Turn BN_FLG_CONSTTIME flag on, so that when BN_div is invoked,
+ * BN_div_no_branch will be called eventually.
+ */
+ {
+ BIGNUM local_A;
+ bn_init(&local_A);
+ BN_with_flags(&local_A, A, BN_FLG_CONSTTIME);
+
+ /* (D, M) := (A/B, A%B) ... */
+ if (!BN_div(D, M, &local_A, B, ctx))
+ goto err;
+ /* Ensure local_A goes out of scope before any further use of A */
+ }
+
+ /*-
+ * Now
+ * A = D*B + M;
+ * thus we have
+ * (**) sign*Y*a == D*B + M (mod |n|).
+ */
+
+ tmp = A; /* keep the BIGNUM object, the value does not
+ * matter */
+
+ /* (A, B) := (B, A mod B) ... */
+ A = B;
+ B = M;
+ /* ... so we have 0 <= B < A again */
+
+ /*-
+ * Since the former M is now B and the former B is now A,
+ * (**) translates into
+ * sign*Y*a == D*A + B (mod |n|),
+ * i.e.
+ * sign*Y*a - D*A == B (mod |n|).
+ * Similarly, (*) translates into
+ * -sign*X*a == A (mod |n|).
+ *
+ * Thus,
+ * sign*Y*a + D*sign*X*a == B (mod |n|),
+ * i.e.
+ * sign*(Y + D*X)*a == B (mod |n|).
+ *
+ * So if we set (X, Y, sign) := (Y + D*X, X, -sign), we arrive back at
+ * -sign*X*a == B (mod |n|),
+ * sign*Y*a == A (mod |n|).
+ * Note that X and Y stay non-negative all the time.
+ */
+
+ if (!BN_mul(tmp, D, X, ctx))
+ goto err;
+ if (!BN_add(tmp, tmp, Y))
+ goto err;
+
+ M = Y; /* keep the BIGNUM object, the value does not
+ * matter */
+ Y = X;
+ X = tmp;
+ sign = -sign;
+ }
+
+ /*-
+ * The while loop (Euclid's algorithm) ends when
+ * A == gcd(a,n);
+ * we have
+ * sign*Y*a == A (mod |n|),
+ * where Y is non-negative.
+ */
+
+ if (sign < 0) {
+ if (!BN_sub(Y, n, Y))
+ goto err;
+ }
+ /* Now Y*a == A (mod |n|). */
+
+ if (BN_is_one(A)) {
+ /* Y*a == 1 (mod |n|) */
+ if (!Y->neg && BN_ucmp(Y, n) < 0) {
+ if (!BN_copy(R, Y))
+ goto err;
+ } else {
+ if (!BN_nnmod(R, Y, n, ctx))
+ goto err;
+ }
+ } else {
+ *pnoinv = 1;
+ /* caller sets the BN_R_NO_INVERSE error */
+ goto err;
+ }
+
+ ret = R;
+ *pnoinv = 0;
+
+ err:
+ if ((ret == NULL) && (in == NULL))
+ BN_free(R);
+ BN_CTX_end(ctx);
+ bn_check_top(ret);
+ return ret;
}
-/*
- * This is an internal function, we assume all callers pass valid arguments:
- * all pointers passed here are assumed non-NULL.
- */
+/*
+ * This is an internal function, we assume all callers pass valid arguments:
+ * all pointers passed here are assumed non-NULL.
+ */
BIGNUM *int_bn_mod_inverse(BIGNUM *in,
const BIGNUM *a, const BIGNUM *n, BN_CTX *ctx,
int *pnoinv)
@@ -203,15 +203,15 @@ BIGNUM *int_bn_mod_inverse(BIGNUM *in,
/* This is invalid input so we don't worry about constant time here */
if (BN_abs_is_word(n, 1) || BN_is_zero(n)) {
- *pnoinv = 1;
+ *pnoinv = 1;
return NULL;
}
- *pnoinv = 0;
+ *pnoinv = 0;
if ((BN_get_flags(a, BN_FLG_CONSTTIME) != 0)
|| (BN_get_flags(n, BN_FLG_CONSTTIME) != 0)) {
- return bn_mod_inverse_no_branch(in, a, n, ctx, pnoinv);
+ return bn_mod_inverse_no_branch(in, a, n, ctx, pnoinv);
}
bn_check_top(a);
@@ -497,7 +497,7 @@ BIGNUM *int_bn_mod_inverse(BIGNUM *in,
goto err;
}
} else {
- *pnoinv = 1;
+ *pnoinv = 1;
goto err;
}
ret = R;
@@ -509,27 +509,27 @@ BIGNUM *int_bn_mod_inverse(BIGNUM *in,
return ret;
}
-/* solves ax == 1 (mod n) */
-BIGNUM *BN_mod_inverse(BIGNUM *in,
- const BIGNUM *a, const BIGNUM *n, BN_CTX *ctx)
+/* solves ax == 1 (mod n) */
+BIGNUM *BN_mod_inverse(BIGNUM *in,
+ const BIGNUM *a, const BIGNUM *n, BN_CTX *ctx)
{
- BN_CTX *new_ctx = NULL;
- BIGNUM *rv;
- int noinv = 0;
-
- if (ctx == NULL) {
- ctx = new_ctx = BN_CTX_new();
- if (ctx == NULL) {
- BNerr(BN_F_BN_MOD_INVERSE, ERR_R_MALLOC_FAILURE);
- return NULL;
+ BN_CTX *new_ctx = NULL;
+ BIGNUM *rv;
+ int noinv = 0;
+
+ if (ctx == NULL) {
+ ctx = new_ctx = BN_CTX_new();
+ if (ctx == NULL) {
+ BNerr(BN_F_BN_MOD_INVERSE, ERR_R_MALLOC_FAILURE);
+ return NULL;
}
}
- rv = int_bn_mod_inverse(in, a, n, ctx, &noinv);
- if (noinv)
- BNerr(BN_F_BN_MOD_INVERSE, BN_R_NO_INVERSE);
- BN_CTX_free(new_ctx);
- return rv;
+ rv = int_bn_mod_inverse(in, a, n, ctx, &noinv);
+ if (noinv)
+ BNerr(BN_F_BN_MOD_INVERSE, BN_R_NO_INVERSE);
+ BN_CTX_free(new_ctx);
+ return rv;
}
/*-
diff --git a/contrib/libs/openssl/crypto/bn/bn_lib.c b/contrib/libs/openssl/crypto/bn/bn_lib.c
index 33776419a0..eb4a31849b 100644
--- a/contrib/libs/openssl/crypto/bn/bn_lib.c
+++ b/contrib/libs/openssl/crypto/bn/bn_lib.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -87,15 +87,15 @@ const BIGNUM *BN_value_one(void)
return &const_one;
}
-/*
- * Old Visual Studio ARM compiler miscompiles BN_num_bits_word()
- * https://mta.openssl.org/pipermail/openssl-users/2018-August/008465.html
- */
-#if defined(_MSC_VER) && defined(_ARM_) && defined(_WIN32_WCE) \
- && _MSC_VER>=1400 && _MSC_VER<1501
-# define MS_BROKEN_BN_num_bits_word
-# pragma optimize("", off)
-#endif
+/*
+ * Old Visual Studio ARM compiler miscompiles BN_num_bits_word()
+ * https://mta.openssl.org/pipermail/openssl-users/2018-August/008465.html
+ */
+#if defined(_MSC_VER) && defined(_ARM_) && defined(_WIN32_WCE) \
+ && _MSC_VER>=1400 && _MSC_VER<1501
+# define MS_BROKEN_BN_num_bits_word
+# pragma optimize("", off)
+#endif
int BN_num_bits_word(BN_ULONG l)
{
BN_ULONG x, mask;
@@ -140,9 +140,9 @@ int BN_num_bits_word(BN_ULONG l)
return bits;
}
-#ifdef MS_BROKEN_BN_num_bits_word
-# pragma optimize("", on)
-#endif
+#ifdef MS_BROKEN_BN_num_bits_word
+# pragma optimize("", on)
+#endif
/*
* This function still leaks `a->dmax`: it's caller's responsibility to
@@ -334,19 +334,19 @@ BIGNUM *BN_dup(const BIGNUM *a)
BIGNUM *BN_copy(BIGNUM *a, const BIGNUM *b)
{
- int bn_words;
-
+ int bn_words;
+
bn_check_top(b);
- bn_words = BN_get_flags(b, BN_FLG_CONSTTIME) ? b->dmax : b->top;
-
+ bn_words = BN_get_flags(b, BN_FLG_CONSTTIME) ? b->dmax : b->top;
+
if (a == b)
return a;
- if (bn_wexpand(a, bn_words) == NULL)
+ if (bn_wexpand(a, bn_words) == NULL)
return NULL;
if (b->top > 0)
- memcpy(a->d, b->d, sizeof(b->d[0]) * bn_words);
+ memcpy(a->d, b->d, sizeof(b->d[0]) * bn_words);
a->neg = b->neg;
a->top = b->top;
diff --git a/contrib/libs/openssl/crypto/bn/bn_mpi.c b/contrib/libs/openssl/crypto/bn/bn_mpi.c
index d8fccac030..0902da5d07 100644
--- a/contrib/libs/openssl/crypto/bn/bn_mpi.c
+++ b/contrib/libs/openssl/crypto/bn/bn_mpi.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -45,7 +45,7 @@ BIGNUM *BN_mpi2bn(const unsigned char *d, int n, BIGNUM *ain)
int neg = 0;
BIGNUM *a = NULL;
- if (n < 4 || (d[0] & 0x80) != 0) {
+ if (n < 4 || (d[0] & 0x80) != 0) {
BNerr(BN_F_BN_MPI2BN, BN_R_INVALID_LENGTH);
return NULL;
}
diff --git a/contrib/libs/openssl/crypto/bn/bn_prime.h b/contrib/libs/openssl/crypto/bn/bn_prime.h
index e7116b777c..1a25c28577 100644
--- a/contrib/libs/openssl/crypto/bn/bn_prime.h
+++ b/contrib/libs/openssl/crypto/bn/bn_prime.h
@@ -2,7 +2,7 @@
* WARNING: do not edit!
* Generated by crypto/bn/bn_prime.pl
*
- * Copyright 1998-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1998-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
diff --git a/contrib/libs/openssl/crypto/buildinf-android_arm.h b/contrib/libs/openssl/crypto/buildinf-android_arm.h
index 5ad3bd399a..e8d19dacd9 100644
--- a/contrib/libs/openssl/crypto/buildinf-android_arm.h
+++ b/contrib/libs/openssl/crypto/buildinf-android_arm.h
@@ -1,71 +1,71 @@
-/*
- * WARNING: do not edit!
- * Generated by util/mkbuildinf.pl
- *
- * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
- *
- * Licensed under the OpenSSL license (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
- */
-
-#define PLATFORM "platform: android-arm"
-#define DATE "built on: Wed Oct 20 11:16:57 2021 UTC"
-
-/*
- * Generate compiler_flags as an array of individual characters. This is a
- * workaround for the situation where CFLAGS gets too long for a C90 string
- * literal
- */
-static const char compiler_flags[] = {
- 'c','o','m','p','i','l','e','r',':',' ','/','h','o','m','e','/',
- 'h','e','r','e','t','i','c','/','o','p','e','n','s','s','l','_',
- 'b','u','i','l','d','/','n','d','k','/','/','l','l','v','m','-',
- 't','o','o','l','c','h','a','i','n','/','b','i','n','/','c','l',
- 'a','n','g',' ','-','f','P','I','C',' ','-','p','t','h','r','e',
- 'a','d',' ',' ','-','t','a','r','g','e','t',' ','a','r','m','v',
- '7','a','-','l','i','n','u','x','-','a','n','d','r','o','i','d',
- 'e','a','b','i',' ','-','g','c','c','-','t','o','o','l','c','h',
- 'a','i','n',' ','/','t','o','o','l','c','h','a','i','n','s','/',
- 'a','r','m','-','l','i','n','u','x','-','a','n','d','r','o','i',
- 'd','e','a','b','i','-','4','.','9','/','p','r','e','b','u','i',
- 'l','t','/','l','i','n','u','x','-','x','8','6','_','6','4',' ',
- '-','-','s','y','s','r','o','o','t','=','/','p','l','a','t','f',
- 'o','r','m','s','/','a','n','d','r','o','i','d','-','2','9','/',
- 'a','r','c','h','-','a','r','m',' ','-','W','a',',','-','-','n',
- 'o','e','x','e','c','s','t','a','c','k',' ','-','Q','u','n','u',
- 's','e','d','-','a','r','g','u','m','e','n','t','s',' ','-','I',
- '/','h','o','m','e','/','h','e','r','e','t','i','c','/','o','p',
- 'e','n','s','s','l','_','b','u','i','l','d','/','n','d','k','/',
- '/','s','y','s','r','o','o','t','/','u','s','r','/','i','n','c',
- 'l','u','d','e',' ','-','I','/','h','o','m','e','/','h','e','r',
- 'e','t','i','c','/','o','p','e','n','s','s','l','_','b','u','i',
- 'l','d','/','n','d','k','/','/','t','o','o','l','c','h','a','i',
- 'n','s','/','l','l','v','m','/','p','r','e','b','u','i','l','t',
- '/','l','i','n','u','x','-','x','8','6','_','6','4','/','s','y',
- 's','r','o','o','t','/','u','s','r','/','i','n','c','l','u','d',
- 'e','/','i','6','8','6','-','l','i','n','u','x','-','a','n','d',
- 'r','o','i','d',' ','-','D','O','P','E','N','S','S','L','_','U',
- 'S','E','_','N','O','D','E','L','E','T','E',' ','-','D','O','P',
- 'E','N','S','S','L','_','P','I','C',' ','-','D','O','P','E','N',
- 'S','S','L','_','C','P','U','I','D','_','O','B','J',' ','-','D',
- 'O','P','E','N','S','S','L','_','B','N','_','A','S','M','_','M',
- 'O','N','T',' ','-','D','O','P','E','N','S','S','L','_','B','N',
- '_','A','S','M','_','G','F','2','m',' ','-','D','S','H','A','1',
- '_','A','S','M',' ','-','D','S','H','A','2','5','6','_','A','S',
- 'M',' ','-','D','S','H','A','5','1','2','_','A','S','M',' ','-',
- 'D','K','E','C','C','A','K','1','6','0','0','_','A','S','M',' ',
- '-','D','A','E','S','_','A','S','M',' ','-','D','B','S','A','E',
- 'S','_','A','S','M',' ','-','D','G','H','A','S','H','_','A','S',
- 'M',' ','-','D','E','C','P','_','N','I','S','T','Z','2','5','6',
- '_','A','S','M',' ','-','D','P','O','L','Y','1','3','0','5','_',
- 'A','S','M',' ','-','D','_','_','A','N','D','R','O','I','D','_',
- 'A','P','I','_','_','=','2','9',' ','-','i','s','y','s','t','e',
- 'm',' ','/','s','y','s','r','o','o','t','/','u','s','r','/','i',
- 'n','c','l','u','d','e','/','a','r','m','-','l','i','n','u','x',
- '-','a','n','d','r','o','i','d','e','a','b','i',' ','-','i','s',
- 'y','s','t','e','m',' ','/','s','y','s','r','o','o','t','/','u',
- 's','r','/','i','n','c','l','u','d','e',' ','-','D','Z','L','I',
- 'B',' ','-','D','N','D','E','B','U','G','\0'
-};
+/*
+ * WARNING: do not edit!
+ * Generated by util/mkbuildinf.pl
+ *
+ * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
+ *
+ * Licensed under the OpenSSL license (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
+ */
+
+#define PLATFORM "platform: android-arm"
+#define DATE "built on: Wed Oct 20 11:16:57 2021 UTC"
+
+/*
+ * Generate compiler_flags as an array of individual characters. This is a
+ * workaround for the situation where CFLAGS gets too long for a C90 string
+ * literal
+ */
+static const char compiler_flags[] = {
+ 'c','o','m','p','i','l','e','r',':',' ','/','h','o','m','e','/',
+ 'h','e','r','e','t','i','c','/','o','p','e','n','s','s','l','_',
+ 'b','u','i','l','d','/','n','d','k','/','/','l','l','v','m','-',
+ 't','o','o','l','c','h','a','i','n','/','b','i','n','/','c','l',
+ 'a','n','g',' ','-','f','P','I','C',' ','-','p','t','h','r','e',
+ 'a','d',' ',' ','-','t','a','r','g','e','t',' ','a','r','m','v',
+ '7','a','-','l','i','n','u','x','-','a','n','d','r','o','i','d',
+ 'e','a','b','i',' ','-','g','c','c','-','t','o','o','l','c','h',
+ 'a','i','n',' ','/','t','o','o','l','c','h','a','i','n','s','/',
+ 'a','r','m','-','l','i','n','u','x','-','a','n','d','r','o','i',
+ 'd','e','a','b','i','-','4','.','9','/','p','r','e','b','u','i',
+ 'l','t','/','l','i','n','u','x','-','x','8','6','_','6','4',' ',
+ '-','-','s','y','s','r','o','o','t','=','/','p','l','a','t','f',
+ 'o','r','m','s','/','a','n','d','r','o','i','d','-','2','9','/',
+ 'a','r','c','h','-','a','r','m',' ','-','W','a',',','-','-','n',
+ 'o','e','x','e','c','s','t','a','c','k',' ','-','Q','u','n','u',
+ 's','e','d','-','a','r','g','u','m','e','n','t','s',' ','-','I',
+ '/','h','o','m','e','/','h','e','r','e','t','i','c','/','o','p',
+ 'e','n','s','s','l','_','b','u','i','l','d','/','n','d','k','/',
+ '/','s','y','s','r','o','o','t','/','u','s','r','/','i','n','c',
+ 'l','u','d','e',' ','-','I','/','h','o','m','e','/','h','e','r',
+ 'e','t','i','c','/','o','p','e','n','s','s','l','_','b','u','i',
+ 'l','d','/','n','d','k','/','/','t','o','o','l','c','h','a','i',
+ 'n','s','/','l','l','v','m','/','p','r','e','b','u','i','l','t',
+ '/','l','i','n','u','x','-','x','8','6','_','6','4','/','s','y',
+ 's','r','o','o','t','/','u','s','r','/','i','n','c','l','u','d',
+ 'e','/','i','6','8','6','-','l','i','n','u','x','-','a','n','d',
+ 'r','o','i','d',' ','-','D','O','P','E','N','S','S','L','_','U',
+ 'S','E','_','N','O','D','E','L','E','T','E',' ','-','D','O','P',
+ 'E','N','S','S','L','_','P','I','C',' ','-','D','O','P','E','N',
+ 'S','S','L','_','C','P','U','I','D','_','O','B','J',' ','-','D',
+ 'O','P','E','N','S','S','L','_','B','N','_','A','S','M','_','M',
+ 'O','N','T',' ','-','D','O','P','E','N','S','S','L','_','B','N',
+ '_','A','S','M','_','G','F','2','m',' ','-','D','S','H','A','1',
+ '_','A','S','M',' ','-','D','S','H','A','2','5','6','_','A','S',
+ 'M',' ','-','D','S','H','A','5','1','2','_','A','S','M',' ','-',
+ 'D','K','E','C','C','A','K','1','6','0','0','_','A','S','M',' ',
+ '-','D','A','E','S','_','A','S','M',' ','-','D','B','S','A','E',
+ 'S','_','A','S','M',' ','-','D','G','H','A','S','H','_','A','S',
+ 'M',' ','-','D','E','C','P','_','N','I','S','T','Z','2','5','6',
+ '_','A','S','M',' ','-','D','P','O','L','Y','1','3','0','5','_',
+ 'A','S','M',' ','-','D','_','_','A','N','D','R','O','I','D','_',
+ 'A','P','I','_','_','=','2','9',' ','-','i','s','y','s','t','e',
+ 'm',' ','/','s','y','s','r','o','o','t','/','u','s','r','/','i',
+ 'n','c','l','u','d','e','/','a','r','m','-','l','i','n','u','x',
+ '-','a','n','d','r','o','i','d','e','a','b','i',' ','-','i','s',
+ 'y','s','t','e','m',' ','/','s','y','s','r','o','o','t','/','u',
+ 's','r','/','i','n','c','l','u','d','e',' ','-','D','Z','L','I',
+ 'B',' ','-','D','N','D','E','B','U','G','\0'
+};
diff --git a/contrib/libs/openssl/crypto/buildinf-android_arm64.h b/contrib/libs/openssl/crypto/buildinf-android_arm64.h
index 44dddf24fd..5c65c99653 100644
--- a/contrib/libs/openssl/crypto/buildinf-android_arm64.h
+++ b/contrib/libs/openssl/crypto/buildinf-android_arm64.h
@@ -1,68 +1,68 @@
-/*
- * WARNING: do not edit!
- * Generated by util/mkbuildinf.pl
- *
- * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
- *
- * Licensed under the OpenSSL license (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
- */
-
-#define PLATFORM "platform: android-arm64"
-#define DATE "built on: Wed Oct 20 11:19:07 2021 UTC"
-
-/*
- * Generate compiler_flags as an array of individual characters. This is a
- * workaround for the situation where CFLAGS gets too long for a C90 string
- * literal
- */
-static const char compiler_flags[] = {
- 'c','o','m','p','i','l','e','r',':',' ','/','h','o','m','e','/',
- 'h','e','r','e','t','i','c','/','o','p','e','n','s','s','l','_',
- 'b','u','i','l','d','/','n','d','k','/','/','l','l','v','m','-',
- 't','o','o','l','c','h','a','i','n','/','b','i','n','/','c','l',
- 'a','n','g',' ','-','f','P','I','C',' ','-','p','t','h','r','e',
- 'a','d',' ',' ','-','t','a','r','g','e','t',' ','a','a','r','c',
- 'h','6','4','-','l','i','n','u','x','-','a','n','d','r','o','i',
- 'd',' ','-','g','c','c','-','t','o','o','l','c','h','a','i','n',
- ' ','/','t','o','o','l','c','h','a','i','n','s','/','a','a','r',
- 'c','h','6','4','-','l','i','n','u','x','-','a','n','d','r','o',
- 'i','d','-','4','.','9','/','p','r','e','b','u','i','l','t','/',
- 'l','i','n','u','x','-','x','8','6','_','6','4',' ','-','-','s',
- 'y','s','r','o','o','t','=','/','p','l','a','t','f','o','r','m',
- 's','/','a','n','d','r','o','i','d','-','2','9','/','a','r','c',
- 'h','-','a','r','m','6','4',' ','-','W','a',',','-','-','n','o',
- 'e','x','e','c','s','t','a','c','k',' ','-','Q','u','n','u','s',
- 'e','d','-','a','r','g','u','m','e','n','t','s',' ','-','I','/',
- 'h','o','m','e','/','h','e','r','e','t','i','c','/','o','p','e',
- 'n','s','s','l','_','b','u','i','l','d','/','n','d','k','/','/',
- 's','y','s','r','o','o','t','/','u','s','r','/','i','n','c','l',
- 'u','d','e',' ','-','I','/','h','o','m','e','/','h','e','r','e',
- 't','i','c','/','o','p','e','n','s','s','l','_','b','u','i','l',
- 'd','/','n','d','k','/','/','t','o','o','l','c','h','a','i','n',
- 's','/','l','l','v','m','/','p','r','e','b','u','i','l','t','/',
- 'l','i','n','u','x','-','x','8','6','_','6','4','/','s','y','s',
- 'r','o','o','t','/','u','s','r','/','i','n','c','l','u','d','e',
- '/','i','6','8','6','-','l','i','n','u','x','-','a','n','d','r',
- 'o','i','d',' ','-','D','O','P','E','N','S','S','L','_','U','S',
- 'E','_','N','O','D','E','L','E','T','E',' ','-','D','O','P','E',
- 'N','S','S','L','_','P','I','C',' ','-','D','O','P','E','N','S',
- 'S','L','_','C','P','U','I','D','_','O','B','J',' ','-','D','O',
- 'P','E','N','S','S','L','_','B','N','_','A','S','M','_','M','O',
- 'N','T',' ','-','D','S','H','A','1','_','A','S','M',' ','-','D',
- 'S','H','A','2','5','6','_','A','S','M',' ','-','D','S','H','A',
- '5','1','2','_','A','S','M',' ','-','D','K','E','C','C','A','K',
- '1','6','0','0','_','A','S','M',' ','-','D','V','P','A','E','S',
- '_','A','S','M',' ','-','D','E','C','P','_','N','I','S','T','Z',
- '2','5','6','_','A','S','M',' ','-','D','P','O','L','Y','1','3',
- '0','5','_','A','S','M',' ','-','D','_','_','A','N','D','R','O',
- 'I','D','_','A','P','I','_','_','=','2','9',' ','-','i','s','y',
- 's','t','e','m',' ','/','s','y','s','r','o','o','t','/','u','s',
- 'r','/','i','n','c','l','u','d','e','/','a','a','r','c','h','6',
- '4','-','l','i','n','u','x','-','a','n','d','r','o','i','d',' ',
- '-','i','s','y','s','t','e','m',' ','/','s','y','s','r','o','o',
- 't','/','u','s','r','/','i','n','c','l','u','d','e',' ','-','D',
- 'Z','L','I','B',' ','-','D','N','D','E','B','U','G','\0'
-};
+/*
+ * WARNING: do not edit!
+ * Generated by util/mkbuildinf.pl
+ *
+ * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
+ *
+ * Licensed under the OpenSSL license (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
+ */
+
+#define PLATFORM "platform: android-arm64"
+#define DATE "built on: Wed Oct 20 11:19:07 2021 UTC"
+
+/*
+ * Generate compiler_flags as an array of individual characters. This is a
+ * workaround for the situation where CFLAGS gets too long for a C90 string
+ * literal
+ */
+static const char compiler_flags[] = {
+ 'c','o','m','p','i','l','e','r',':',' ','/','h','o','m','e','/',
+ 'h','e','r','e','t','i','c','/','o','p','e','n','s','s','l','_',
+ 'b','u','i','l','d','/','n','d','k','/','/','l','l','v','m','-',
+ 't','o','o','l','c','h','a','i','n','/','b','i','n','/','c','l',
+ 'a','n','g',' ','-','f','P','I','C',' ','-','p','t','h','r','e',
+ 'a','d',' ',' ','-','t','a','r','g','e','t',' ','a','a','r','c',
+ 'h','6','4','-','l','i','n','u','x','-','a','n','d','r','o','i',
+ 'd',' ','-','g','c','c','-','t','o','o','l','c','h','a','i','n',
+ ' ','/','t','o','o','l','c','h','a','i','n','s','/','a','a','r',
+ 'c','h','6','4','-','l','i','n','u','x','-','a','n','d','r','o',
+ 'i','d','-','4','.','9','/','p','r','e','b','u','i','l','t','/',
+ 'l','i','n','u','x','-','x','8','6','_','6','4',' ','-','-','s',
+ 'y','s','r','o','o','t','=','/','p','l','a','t','f','o','r','m',
+ 's','/','a','n','d','r','o','i','d','-','2','9','/','a','r','c',
+ 'h','-','a','r','m','6','4',' ','-','W','a',',','-','-','n','o',
+ 'e','x','e','c','s','t','a','c','k',' ','-','Q','u','n','u','s',
+ 'e','d','-','a','r','g','u','m','e','n','t','s',' ','-','I','/',
+ 'h','o','m','e','/','h','e','r','e','t','i','c','/','o','p','e',
+ 'n','s','s','l','_','b','u','i','l','d','/','n','d','k','/','/',
+ 's','y','s','r','o','o','t','/','u','s','r','/','i','n','c','l',
+ 'u','d','e',' ','-','I','/','h','o','m','e','/','h','e','r','e',
+ 't','i','c','/','o','p','e','n','s','s','l','_','b','u','i','l',
+ 'd','/','n','d','k','/','/','t','o','o','l','c','h','a','i','n',
+ 's','/','l','l','v','m','/','p','r','e','b','u','i','l','t','/',
+ 'l','i','n','u','x','-','x','8','6','_','6','4','/','s','y','s',
+ 'r','o','o','t','/','u','s','r','/','i','n','c','l','u','d','e',
+ '/','i','6','8','6','-','l','i','n','u','x','-','a','n','d','r',
+ 'o','i','d',' ','-','D','O','P','E','N','S','S','L','_','U','S',
+ 'E','_','N','O','D','E','L','E','T','E',' ','-','D','O','P','E',
+ 'N','S','S','L','_','P','I','C',' ','-','D','O','P','E','N','S',
+ 'S','L','_','C','P','U','I','D','_','O','B','J',' ','-','D','O',
+ 'P','E','N','S','S','L','_','B','N','_','A','S','M','_','M','O',
+ 'N','T',' ','-','D','S','H','A','1','_','A','S','M',' ','-','D',
+ 'S','H','A','2','5','6','_','A','S','M',' ','-','D','S','H','A',
+ '5','1','2','_','A','S','M',' ','-','D','K','E','C','C','A','K',
+ '1','6','0','0','_','A','S','M',' ','-','D','V','P','A','E','S',
+ '_','A','S','M',' ','-','D','E','C','P','_','N','I','S','T','Z',
+ '2','5','6','_','A','S','M',' ','-','D','P','O','L','Y','1','3',
+ '0','5','_','A','S','M',' ','-','D','_','_','A','N','D','R','O',
+ 'I','D','_','A','P','I','_','_','=','2','9',' ','-','i','s','y',
+ 's','t','e','m',' ','/','s','y','s','r','o','o','t','/','u','s',
+ 'r','/','i','n','c','l','u','d','e','/','a','a','r','c','h','6',
+ '4','-','l','i','n','u','x','-','a','n','d','r','o','i','d',' ',
+ '-','i','s','y','s','t','e','m',' ','/','s','y','s','r','o','o',
+ 't','/','u','s','r','/','i','n','c','l','u','d','e',' ','-','D',
+ 'Z','L','I','B',' ','-','D','N','D','E','B','U','G','\0'
+};
diff --git a/contrib/libs/openssl/crypto/buildinf-android_x86.h b/contrib/libs/openssl/crypto/buildinf-android_x86.h
index 5efcaa48f2..c89f944cdf 100644
--- a/contrib/libs/openssl/crypto/buildinf-android_x86.h
+++ b/contrib/libs/openssl/crypto/buildinf-android_x86.h
@@ -1,75 +1,75 @@
-/*
- * WARNING: do not edit!
- * Generated by util/mkbuildinf.pl
- *
- * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
- *
- * Licensed under the OpenSSL license (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
- */
-
-#define PLATFORM "platform: android-x86"
-#define DATE "built on: Tue Oct 19 19:59:02 2021 UTC"
-
-/*
- * Generate compiler_flags as an array of individual characters. This is a
- * workaround for the situation where CFLAGS gets too long for a C90 string
- * literal
- */
-static const char compiler_flags[] = {
- 'c','o','m','p','i','l','e','r',':',' ','/','h','o','m','e','/',
- 'h','e','r','e','t','i','c','/','o','p','e','n','s','s','l','_',
- 'b','u','i','l','d','/','n','d','k','/','/','l','l','v','m','-',
- 't','o','o','l','c','h','a','i','n','/','b','i','n','/','c','l',
- 'a','n','g',' ','-','f','P','I','C',' ','-','p','t','h','r','e',
- 'a','d',' ',' ','-','t','a','r','g','e','t',' ','i','6','8','6',
- '-','l','i','n','u','x','-','a','n','d','r','o','i','d',' ','-',
- 'g','c','c','-','t','o','o','l','c','h','a','i','n',' ','/','t',
- 'o','o','l','c','h','a','i','n','s','/','x','8','6','-','4','.',
- '9','/','p','r','e','b','u','i','l','t','/','l','i','n','u','x',
- '-','x','8','6','_','6','4',' ','-','-','s','y','s','r','o','o',
- 't','=','/','p','l','a','t','f','o','r','m','s','/','a','n','d',
- 'r','o','i','d','-','2','9','/','a','r','c','h','-','x','8','6',
- ' ','-','W','a',',','-','-','n','o','e','x','e','c','s','t','a',
- 'c','k',' ','-','Q','u','n','u','s','e','d','-','a','r','g','u',
- 'm','e','n','t','s',' ','-','I','/','h','o','m','e','/','h','e',
- 'r','e','t','i','c','/','o','p','e','n','s','s','l','_','b','u',
- 'i','l','d','/','n','d','k','/','/','s','y','s','r','o','o','t',
- '/','u','s','r','/','i','n','c','l','u','d','e',' ','-','I','/',
- 'h','o','m','e','/','h','e','r','e','t','i','c','/','o','p','e',
- 'n','s','s','l','_','b','u','i','l','d','/','n','d','k','/','/',
- 't','o','o','l','c','h','a','i','n','s','/','l','l','v','m','/',
- 'p','r','e','b','u','i','l','t','/','l','i','n','u','x','-','x',
- '8','6','_','6','4','/','s','y','s','r','o','o','t','/','u','s',
- 'r','/','i','n','c','l','u','d','e','/','i','6','8','6','-','l',
- 'i','n','u','x','-','a','n','d','r','o','i','d',' ','-','D','O',
- 'P','E','N','S','S','L','_','U','S','E','_','N','O','D','E','L',
- 'E','T','E',' ','-','D','O','P','E','N','S','S','L','_','P','I',
- 'C',' ','-','D','O','P','E','N','S','S','L','_','C','P','U','I',
- 'D','_','O','B','J',' ','-','D','O','P','E','N','S','S','L','_',
- 'B','N','_','A','S','M','_','P','A','R','T','_','W','O','R','D',
- 'S',' ','-','D','O','P','E','N','S','S','L','_','I','A','3','2',
- '_','S','S','E','2',' ','-','D','O','P','E','N','S','S','L','_',
- 'B','N','_','A','S','M','_','M','O','N','T',' ','-','D','O','P',
- 'E','N','S','S','L','_','B','N','_','A','S','M','_','G','F','2',
- 'm',' ','-','D','S','H','A','1','_','A','S','M',' ','-','D','S',
- 'H','A','2','5','6','_','A','S','M',' ','-','D','S','H','A','5',
- '1','2','_','A','S','M',' ','-','D','R','C','4','_','A','S','M',
- ' ','-','D','M','D','5','_','A','S','M',' ','-','D','R','M','D',
- '1','6','0','_','A','S','M',' ','-','D','A','E','S','N','I','_',
- 'A','S','M',' ','-','D','V','P','A','E','S','_','A','S','M',' ',
- '-','D','W','H','I','R','L','P','O','O','L','_','A','S','M',' ',
- '-','D','G','H','A','S','H','_','A','S','M',' ','-','D','E','C',
- 'P','_','N','I','S','T','Z','2','5','6','_','A','S','M',' ','-',
- 'D','P','O','L','Y','1','3','0','5','_','A','S','M',' ','-','D',
- '_','_','A','N','D','R','O','I','D','_','A','P','I','_','_','=',
- '2','9',' ','-','i','s','y','s','t','e','m',' ','/','s','y','s',
- 'r','o','o','t','/','u','s','r','/','i','n','c','l','u','d','e',
- '/','i','6','8','6','-','l','i','n','u','x','-','a','n','d','r',
- 'o','i','d',' ','-','i','s','y','s','t','e','m',' ','/','s','y',
- 's','r','o','o','t','/','u','s','r','/','i','n','c','l','u','d',
- 'e',' ','-','D','Z','L','I','B',' ','-','D','N','D','E','B','U',
- 'G','\0'
-};
+/*
+ * WARNING: do not edit!
+ * Generated by util/mkbuildinf.pl
+ *
+ * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
+ *
+ * Licensed under the OpenSSL license (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
+ */
+
+#define PLATFORM "platform: android-x86"
+#define DATE "built on: Tue Oct 19 19:59:02 2021 UTC"
+
+/*
+ * Generate compiler_flags as an array of individual characters. This is a
+ * workaround for the situation where CFLAGS gets too long for a C90 string
+ * literal
+ */
+static const char compiler_flags[] = {
+ 'c','o','m','p','i','l','e','r',':',' ','/','h','o','m','e','/',
+ 'h','e','r','e','t','i','c','/','o','p','e','n','s','s','l','_',
+ 'b','u','i','l','d','/','n','d','k','/','/','l','l','v','m','-',
+ 't','o','o','l','c','h','a','i','n','/','b','i','n','/','c','l',
+ 'a','n','g',' ','-','f','P','I','C',' ','-','p','t','h','r','e',
+ 'a','d',' ',' ','-','t','a','r','g','e','t',' ','i','6','8','6',
+ '-','l','i','n','u','x','-','a','n','d','r','o','i','d',' ','-',
+ 'g','c','c','-','t','o','o','l','c','h','a','i','n',' ','/','t',
+ 'o','o','l','c','h','a','i','n','s','/','x','8','6','-','4','.',
+ '9','/','p','r','e','b','u','i','l','t','/','l','i','n','u','x',
+ '-','x','8','6','_','6','4',' ','-','-','s','y','s','r','o','o',
+ 't','=','/','p','l','a','t','f','o','r','m','s','/','a','n','d',
+ 'r','o','i','d','-','2','9','/','a','r','c','h','-','x','8','6',
+ ' ','-','W','a',',','-','-','n','o','e','x','e','c','s','t','a',
+ 'c','k',' ','-','Q','u','n','u','s','e','d','-','a','r','g','u',
+ 'm','e','n','t','s',' ','-','I','/','h','o','m','e','/','h','e',
+ 'r','e','t','i','c','/','o','p','e','n','s','s','l','_','b','u',
+ 'i','l','d','/','n','d','k','/','/','s','y','s','r','o','o','t',
+ '/','u','s','r','/','i','n','c','l','u','d','e',' ','-','I','/',
+ 'h','o','m','e','/','h','e','r','e','t','i','c','/','o','p','e',
+ 'n','s','s','l','_','b','u','i','l','d','/','n','d','k','/','/',
+ 't','o','o','l','c','h','a','i','n','s','/','l','l','v','m','/',
+ 'p','r','e','b','u','i','l','t','/','l','i','n','u','x','-','x',
+ '8','6','_','6','4','/','s','y','s','r','o','o','t','/','u','s',
+ 'r','/','i','n','c','l','u','d','e','/','i','6','8','6','-','l',
+ 'i','n','u','x','-','a','n','d','r','o','i','d',' ','-','D','O',
+ 'P','E','N','S','S','L','_','U','S','E','_','N','O','D','E','L',
+ 'E','T','E',' ','-','D','O','P','E','N','S','S','L','_','P','I',
+ 'C',' ','-','D','O','P','E','N','S','S','L','_','C','P','U','I',
+ 'D','_','O','B','J',' ','-','D','O','P','E','N','S','S','L','_',
+ 'B','N','_','A','S','M','_','P','A','R','T','_','W','O','R','D',
+ 'S',' ','-','D','O','P','E','N','S','S','L','_','I','A','3','2',
+ '_','S','S','E','2',' ','-','D','O','P','E','N','S','S','L','_',
+ 'B','N','_','A','S','M','_','M','O','N','T',' ','-','D','O','P',
+ 'E','N','S','S','L','_','B','N','_','A','S','M','_','G','F','2',
+ 'm',' ','-','D','S','H','A','1','_','A','S','M',' ','-','D','S',
+ 'H','A','2','5','6','_','A','S','M',' ','-','D','S','H','A','5',
+ '1','2','_','A','S','M',' ','-','D','R','C','4','_','A','S','M',
+ ' ','-','D','M','D','5','_','A','S','M',' ','-','D','R','M','D',
+ '1','6','0','_','A','S','M',' ','-','D','A','E','S','N','I','_',
+ 'A','S','M',' ','-','D','V','P','A','E','S','_','A','S','M',' ',
+ '-','D','W','H','I','R','L','P','O','O','L','_','A','S','M',' ',
+ '-','D','G','H','A','S','H','_','A','S','M',' ','-','D','E','C',
+ 'P','_','N','I','S','T','Z','2','5','6','_','A','S','M',' ','-',
+ 'D','P','O','L','Y','1','3','0','5','_','A','S','M',' ','-','D',
+ '_','_','A','N','D','R','O','I','D','_','A','P','I','_','_','=',
+ '2','9',' ','-','i','s','y','s','t','e','m',' ','/','s','y','s',
+ 'r','o','o','t','/','u','s','r','/','i','n','c','l','u','d','e',
+ '/','i','6','8','6','-','l','i','n','u','x','-','a','n','d','r',
+ 'o','i','d',' ','-','i','s','y','s','t','e','m',' ','/','s','y',
+ 's','r','o','o','t','/','u','s','r','/','i','n','c','l','u','d',
+ 'e',' ','-','D','Z','L','I','B',' ','-','D','N','D','E','B','U',
+ 'G','\0'
+};
diff --git a/contrib/libs/openssl/crypto/buildinf-android_x86_64.h b/contrib/libs/openssl/crypto/buildinf-android_x86_64.h
index c4a1c696cf..91cec3c04c 100644
--- a/contrib/libs/openssl/crypto/buildinf-android_x86_64.h
+++ b/contrib/libs/openssl/crypto/buildinf-android_x86_64.h
@@ -1,75 +1,75 @@
-/*
- * WARNING: do not edit!
- * Generated by util/mkbuildinf.pl
- *
- * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
- *
- * Licensed under the OpenSSL license (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
- */
-
-#define PLATFORM "platform: android-x86_64"
-#define DATE "built on: Wed Oct 20 10:54:48 2021 UTC"
-
-/*
- * Generate compiler_flags as an array of individual characters. This is a
- * workaround for the situation where CFLAGS gets too long for a C90 string
- * literal
- */
-static const char compiler_flags[] = {
- 'c','o','m','p','i','l','e','r',':',' ','/','h','o','m','e','/',
- 'h','e','r','e','t','i','c','/','o','p','e','n','s','s','l','_',
- 'b','u','i','l','d','/','n','d','k','/','/','l','l','v','m','-',
- 't','o','o','l','c','h','a','i','n','/','b','i','n','/','c','l',
- 'a','n','g',' ','-','f','P','I','C',' ','-','p','t','h','r','e',
- 'a','d',' ',' ','-','t','a','r','g','e','t',' ','x','8','6','_',
- '6','4','-','l','i','n','u','x','-','a','n','d','r','o','i','d',
- ' ','-','g','c','c','-','t','o','o','l','c','h','a','i','n',' ',
- '/','t','o','o','l','c','h','a','i','n','s','/','x','8','6','_',
- '6','4','-','4','.','9','/','p','r','e','b','u','i','l','t','/',
- 'l','i','n','u','x','-','x','8','6','_','6','4',' ','-','-','s',
- 'y','s','r','o','o','t','=','/','p','l','a','t','f','o','r','m',
- 's','/','a','n','d','r','o','i','d','-','2','9','/','a','r','c',
- 'h','-','x','8','6','_','6','4',' ','-','W','a',',','-','-','n',
- 'o','e','x','e','c','s','t','a','c','k',' ','-','Q','u','n','u',
- 's','e','d','-','a','r','g','u','m','e','n','t','s',' ','-','I',
- '/','h','o','m','e','/','h','e','r','e','t','i','c','/','o','p',
- 'e','n','s','s','l','_','b','u','i','l','d','/','n','d','k','/',
- '/','s','y','s','r','o','o','t','/','u','s','r','/','i','n','c',
- 'l','u','d','e',' ','-','I','/','h','o','m','e','/','h','e','r',
- 'e','t','i','c','/','o','p','e','n','s','s','l','_','b','u','i',
- 'l','d','/','n','d','k','/','/','t','o','o','l','c','h','a','i',
- 'n','s','/','l','l','v','m','/','p','r','e','b','u','i','l','t',
- '/','l','i','n','u','x','-','x','8','6','_','6','4','/','s','y',
- 's','r','o','o','t','/','u','s','r','/','i','n','c','l','u','d',
- 'e','/','i','6','8','6','-','l','i','n','u','x','-','a','n','d',
- 'r','o','i','d',' ','-','D','O','P','E','N','S','S','L','_','U',
- 'S','E','_','N','O','D','E','L','E','T','E',' ','-','D','O','P',
- 'E','N','S','S','L','_','P','I','C',' ','-','D','O','P','E','N',
- 'S','S','L','_','C','P','U','I','D','_','O','B','J',' ','-','D',
- 'O','P','E','N','S','S','L','_','I','A','3','2','_','S','S','E',
- '2',' ','-','D','O','P','E','N','S','S','L','_','B','N','_','A',
- 'S','M','_','M','O','N','T',' ','-','D','O','P','E','N','S','S',
- 'L','_','B','N','_','A','S','M','_','M','O','N','T','5',' ','-',
- 'D','O','P','E','N','S','S','L','_','B','N','_','A','S','M','_',
- 'G','F','2','m',' ','-','D','S','H','A','1','_','A','S','M',' ',
- '-','D','S','H','A','2','5','6','_','A','S','M',' ','-','D','S',
- 'H','A','5','1','2','_','A','S','M',' ','-','D','K','E','C','C',
- 'A','K','1','6','0','0','_','A','S','M',' ','-','D','R','C','4',
- '_','A','S','M',' ','-','D','M','D','5','_','A','S','M',' ','-',
- 'D','A','E','S','N','I','_','A','S','M',' ','-','D','V','P','A',
- 'E','S','_','A','S','M',' ','-','D','G','H','A','S','H','_','A',
- 'S','M',' ','-','D','E','C','P','_','N','I','S','T','Z','2','5',
- '6','_','A','S','M',' ','-','D','X','2','5','5','1','9','_','A',
- 'S','M',' ','-','D','P','O','L','Y','1','3','0','5','_','A','S',
- 'M',' ','-','D','_','_','A','N','D','R','O','I','D','_','A','P',
- 'I','_','_','=','2','9',' ','-','i','s','y','s','t','e','m',' ',
- '/','s','y','s','r','o','o','t','/','u','s','r','/','i','n','c',
- 'l','u','d','e','/','x','8','6','_','6','4','-','l','i','n','u',
- 'x','-','a','n','d','r','o','i','d',' ','-','i','s','y','s','t',
- 'e','m',' ','/','s','y','s','r','o','o','t','/','u','s','r','/',
- 'i','n','c','l','u','d','e',' ','-','D','Z','L','I','B',' ','-',
- 'D','N','D','E','B','U','G','\0'
-};
+/*
+ * WARNING: do not edit!
+ * Generated by util/mkbuildinf.pl
+ *
+ * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
+ *
+ * Licensed under the OpenSSL license (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
+ */
+
+#define PLATFORM "platform: android-x86_64"
+#define DATE "built on: Wed Oct 20 10:54:48 2021 UTC"
+
+/*
+ * Generate compiler_flags as an array of individual characters. This is a
+ * workaround for the situation where CFLAGS gets too long for a C90 string
+ * literal
+ */
+static const char compiler_flags[] = {
+ 'c','o','m','p','i','l','e','r',':',' ','/','h','o','m','e','/',
+ 'h','e','r','e','t','i','c','/','o','p','e','n','s','s','l','_',
+ 'b','u','i','l','d','/','n','d','k','/','/','l','l','v','m','-',
+ 't','o','o','l','c','h','a','i','n','/','b','i','n','/','c','l',
+ 'a','n','g',' ','-','f','P','I','C',' ','-','p','t','h','r','e',
+ 'a','d',' ',' ','-','t','a','r','g','e','t',' ','x','8','6','_',
+ '6','4','-','l','i','n','u','x','-','a','n','d','r','o','i','d',
+ ' ','-','g','c','c','-','t','o','o','l','c','h','a','i','n',' ',
+ '/','t','o','o','l','c','h','a','i','n','s','/','x','8','6','_',
+ '6','4','-','4','.','9','/','p','r','e','b','u','i','l','t','/',
+ 'l','i','n','u','x','-','x','8','6','_','6','4',' ','-','-','s',
+ 'y','s','r','o','o','t','=','/','p','l','a','t','f','o','r','m',
+ 's','/','a','n','d','r','o','i','d','-','2','9','/','a','r','c',
+ 'h','-','x','8','6','_','6','4',' ','-','W','a',',','-','-','n',
+ 'o','e','x','e','c','s','t','a','c','k',' ','-','Q','u','n','u',
+ 's','e','d','-','a','r','g','u','m','e','n','t','s',' ','-','I',
+ '/','h','o','m','e','/','h','e','r','e','t','i','c','/','o','p',
+ 'e','n','s','s','l','_','b','u','i','l','d','/','n','d','k','/',
+ '/','s','y','s','r','o','o','t','/','u','s','r','/','i','n','c',
+ 'l','u','d','e',' ','-','I','/','h','o','m','e','/','h','e','r',
+ 'e','t','i','c','/','o','p','e','n','s','s','l','_','b','u','i',
+ 'l','d','/','n','d','k','/','/','t','o','o','l','c','h','a','i',
+ 'n','s','/','l','l','v','m','/','p','r','e','b','u','i','l','t',
+ '/','l','i','n','u','x','-','x','8','6','_','6','4','/','s','y',
+ 's','r','o','o','t','/','u','s','r','/','i','n','c','l','u','d',
+ 'e','/','i','6','8','6','-','l','i','n','u','x','-','a','n','d',
+ 'r','o','i','d',' ','-','D','O','P','E','N','S','S','L','_','U',
+ 'S','E','_','N','O','D','E','L','E','T','E',' ','-','D','O','P',
+ 'E','N','S','S','L','_','P','I','C',' ','-','D','O','P','E','N',
+ 'S','S','L','_','C','P','U','I','D','_','O','B','J',' ','-','D',
+ 'O','P','E','N','S','S','L','_','I','A','3','2','_','S','S','E',
+ '2',' ','-','D','O','P','E','N','S','S','L','_','B','N','_','A',
+ 'S','M','_','M','O','N','T',' ','-','D','O','P','E','N','S','S',
+ 'L','_','B','N','_','A','S','M','_','M','O','N','T','5',' ','-',
+ 'D','O','P','E','N','S','S','L','_','B','N','_','A','S','M','_',
+ 'G','F','2','m',' ','-','D','S','H','A','1','_','A','S','M',' ',
+ '-','D','S','H','A','2','5','6','_','A','S','M',' ','-','D','S',
+ 'H','A','5','1','2','_','A','S','M',' ','-','D','K','E','C','C',
+ 'A','K','1','6','0','0','_','A','S','M',' ','-','D','R','C','4',
+ '_','A','S','M',' ','-','D','M','D','5','_','A','S','M',' ','-',
+ 'D','A','E','S','N','I','_','A','S','M',' ','-','D','V','P','A',
+ 'E','S','_','A','S','M',' ','-','D','G','H','A','S','H','_','A',
+ 'S','M',' ','-','D','E','C','P','_','N','I','S','T','Z','2','5',
+ '6','_','A','S','M',' ','-','D','X','2','5','5','1','9','_','A',
+ 'S','M',' ','-','D','P','O','L','Y','1','3','0','5','_','A','S',
+ 'M',' ','-','D','_','_','A','N','D','R','O','I','D','_','A','P',
+ 'I','_','_','=','2','9',' ','-','i','s','y','s','t','e','m',' ',
+ '/','s','y','s','r','o','o','t','/','u','s','r','/','i','n','c',
+ 'l','u','d','e','/','x','8','6','_','6','4','-','l','i','n','u',
+ 'x','-','a','n','d','r','o','i','d',' ','-','i','s','y','s','t',
+ 'e','m',' ','/','s','y','s','r','o','o','t','/','u','s','r','/',
+ 'i','n','c','l','u','d','e',' ','-','D','Z','L','I','B',' ','-',
+ 'D','N','D','E','B','U','G','\0'
+};
diff --git a/contrib/libs/openssl/crypto/buildinf-ios-arm.h b/contrib/libs/openssl/crypto/buildinf-ios-arm.h
index 900a21a4ac..ab0b9fcab9 100644
--- a/contrib/libs/openssl/crypto/buildinf-ios-arm.h
+++ b/contrib/libs/openssl/crypto/buildinf-ios-arm.h
@@ -1,51 +1,51 @@
-/*
- * WARNING: do not edit!
- * Generated by util/mkbuildinf.pl
- *
- * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
- *
- * Licensed under the OpenSSL license (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
- */
-
-#define PLATFORM "platform: ios-cross"
-#define DATE "built on: Wed Oct 20 15:54:01 2021 UTC"
-
-/*
- * Generate compiler_flags as an array of individual characters. This is a
- * workaround for the situation where CFLAGS gets too long for a C90 string
- * literal
- */
-static const char compiler_flags[] = {
- 'c','o','m','p','i','l','e','r',':',' ','c','c',' ','-','f','P',
- 'I','C',' ','-','a','r','c','h',' ','a','r','m','v','7',' ','-',
- 'm','i','o','s','-','v','e','r','s','i','o','n','-','m','i','n',
- '=','6','.','0','.','0',' ','-','f','n','o','-','c','o','m','m',
- 'o','n',' ','-','i','s','y','s','r','o','o','t',' ','/','S','D',
- 'K','s','/',' ','-','O','3',' ','-','i','s','y','s','r','o','o',
- 't',' ','/','A','p','p','l','i','c','a','t','i','o','n','s','/',
- 'X','c','o','d','e','.','a','p','p','/','C','o','n','t','e','n',
- 't','s','/','D','e','v','e','l','o','p','e','r','/','P','l','a',
- 't','f','o','r','m','s','/','i','P','h','o','n','e','O','S','.',
- 'p','l','a','t','f','o','r','m','/','D','e','v','e','l','o','p',
- 'e','r','/','S','D','K','s','/','i','P','h','o','n','e','O','S',
- '.','s','d','k','/',' ','-','m','i','o','s','-','s','i','m','u',
- 'l','a','t','o','r','-','v','e','r','s','i','o','n','-','m','i',
- 'n','=','9','.','0',' ','-','D','O','P','E','N','S','S','L','_',
- 'P','I','C',' ','-','D','O','P','E','N','S','S','L','_','C','P',
- 'U','I','D','_','O','B','J',' ','-','D','O','P','E','N','S','S',
- 'L','_','B','N','_','A','S','M','_','M','O','N','T',' ','-','D',
- 'O','P','E','N','S','S','L','_','B','N','_','A','S','M','_','G',
- 'F','2','m',' ','-','D','S','H','A','1','_','A','S','M',' ','-',
- 'D','S','H','A','2','5','6','_','A','S','M',' ','-','D','S','H',
- 'A','5','1','2','_','A','S','M',' ','-','D','K','E','C','C','A',
- 'K','1','6','0','0','_','A','S','M',' ','-','D','A','E','S','_',
- 'A','S','M',' ','-','D','B','S','A','E','S','_','A','S','M',' ',
- '-','D','G','H','A','S','H','_','A','S','M',' ','-','D','E','C',
- 'P','_','N','I','S','T','Z','2','5','6','_','A','S','M',' ','-',
- 'D','P','O','L','Y','1','3','0','5','_','A','S','M',' ','-','D',
- '_','R','E','E','N','T','R','A','N','T',' ','-','D','Z','L','I',
- 'B',' ','-','D','N','D','E','B','U','G','\0'
-};
+/*
+ * WARNING: do not edit!
+ * Generated by util/mkbuildinf.pl
+ *
+ * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
+ *
+ * Licensed under the OpenSSL license (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
+ */
+
+#define PLATFORM "platform: ios-cross"
+#define DATE "built on: Wed Oct 20 15:54:01 2021 UTC"
+
+/*
+ * Generate compiler_flags as an array of individual characters. This is a
+ * workaround for the situation where CFLAGS gets too long for a C90 string
+ * literal
+ */
+static const char compiler_flags[] = {
+ 'c','o','m','p','i','l','e','r',':',' ','c','c',' ','-','f','P',
+ 'I','C',' ','-','a','r','c','h',' ','a','r','m','v','7',' ','-',
+ 'm','i','o','s','-','v','e','r','s','i','o','n','-','m','i','n',
+ '=','6','.','0','.','0',' ','-','f','n','o','-','c','o','m','m',
+ 'o','n',' ','-','i','s','y','s','r','o','o','t',' ','/','S','D',
+ 'K','s','/',' ','-','O','3',' ','-','i','s','y','s','r','o','o',
+ 't',' ','/','A','p','p','l','i','c','a','t','i','o','n','s','/',
+ 'X','c','o','d','e','.','a','p','p','/','C','o','n','t','e','n',
+ 't','s','/','D','e','v','e','l','o','p','e','r','/','P','l','a',
+ 't','f','o','r','m','s','/','i','P','h','o','n','e','O','S','.',
+ 'p','l','a','t','f','o','r','m','/','D','e','v','e','l','o','p',
+ 'e','r','/','S','D','K','s','/','i','P','h','o','n','e','O','S',
+ '.','s','d','k','/',' ','-','m','i','o','s','-','s','i','m','u',
+ 'l','a','t','o','r','-','v','e','r','s','i','o','n','-','m','i',
+ 'n','=','9','.','0',' ','-','D','O','P','E','N','S','S','L','_',
+ 'P','I','C',' ','-','D','O','P','E','N','S','S','L','_','C','P',
+ 'U','I','D','_','O','B','J',' ','-','D','O','P','E','N','S','S',
+ 'L','_','B','N','_','A','S','M','_','M','O','N','T',' ','-','D',
+ 'O','P','E','N','S','S','L','_','B','N','_','A','S','M','_','G',
+ 'F','2','m',' ','-','D','S','H','A','1','_','A','S','M',' ','-',
+ 'D','S','H','A','2','5','6','_','A','S','M',' ','-','D','S','H',
+ 'A','5','1','2','_','A','S','M',' ','-','D','K','E','C','C','A',
+ 'K','1','6','0','0','_','A','S','M',' ','-','D','A','E','S','_',
+ 'A','S','M',' ','-','D','B','S','A','E','S','_','A','S','M',' ',
+ '-','D','G','H','A','S','H','_','A','S','M',' ','-','D','E','C',
+ 'P','_','N','I','S','T','Z','2','5','6','_','A','S','M',' ','-',
+ 'D','P','O','L','Y','1','3','0','5','_','A','S','M',' ','-','D',
+ '_','R','E','E','N','T','R','A','N','T',' ','-','D','Z','L','I',
+ 'B',' ','-','D','N','D','E','B','U','G','\0'
+};
diff --git a/contrib/libs/openssl/crypto/buildinf-ios-arm64.h b/contrib/libs/openssl/crypto/buildinf-ios-arm64.h
index 62ccf842ea..cb725a11d3 100644
--- a/contrib/libs/openssl/crypto/buildinf-ios-arm64.h
+++ b/contrib/libs/openssl/crypto/buildinf-ios-arm64.h
@@ -1,48 +1,48 @@
-/*
- * WARNING: do not edit!
- * Generated by util/mkbuildinf.pl
- *
- * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
- *
- * Licensed under the OpenSSL license (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
- */
-
-#define PLATFORM "platform: ios64-cross"
-#define DATE "built on: Wed Oct 20 15:59:29 2021 UTC"
-
-/*
- * Generate compiler_flags as an array of individual characters. This is a
- * workaround for the situation where CFLAGS gets too long for a C90 string
- * literal
- */
-static const char compiler_flags[] = {
- 'c','o','m','p','i','l','e','r',':',' ','c','c',' ','-','f','P',
- 'I','C',' ','-','a','r','c','h',' ','a','r','m','6','4',' ','-',
- 'm','i','o','s','-','v','e','r','s','i','o','n','-','m','i','n',
- '=','7','.','0','.','0',' ','-','f','n','o','-','c','o','m','m',
- 'o','n',' ','-','i','s','y','s','r','o','o','t',' ','/','S','D',
- 'K','s','/',' ','-','O','3',' ','-','i','s','y','s','r','o','o',
- 't',' ','/','A','p','p','l','i','c','a','t','i','o','n','s','/',
- 'X','c','o','d','e','.','a','p','p','/','C','o','n','t','e','n',
- 't','s','/','D','e','v','e','l','o','p','e','r','/','P','l','a',
- 't','f','o','r','m','s','/','i','P','h','o','n','e','O','S','.',
- 'p','l','a','t','f','o','r','m','/','D','e','v','e','l','o','p',
- 'e','r','/','S','D','K','s','/','i','P','h','o','n','e','O','S',
- '.','s','d','k','/',' ','-','m','i','o','s','-','v','e','r','s',
- 'i','o','n','-','m','i','n','=','9','.','0',' ','-','D','O','P',
- 'E','N','S','S','L','_','P','I','C',' ','-','D','O','P','E','N',
- 'S','S','L','_','C','P','U','I','D','_','O','B','J',' ','-','D',
- 'O','P','E','N','S','S','L','_','B','N','_','A','S','M','_','M',
- 'O','N','T',' ','-','D','S','H','A','1','_','A','S','M',' ','-',
- 'D','S','H','A','2','5','6','_','A','S','M',' ','-','D','S','H',
- 'A','5','1','2','_','A','S','M',' ','-','D','K','E','C','C','A',
- 'K','1','6','0','0','_','A','S','M',' ','-','D','V','P','A','E',
- 'S','_','A','S','M',' ','-','D','E','C','P','_','N','I','S','T',
- 'Z','2','5','6','_','A','S','M',' ','-','D','P','O','L','Y','1',
- '3','0','5','_','A','S','M',' ','-','D','_','R','E','E','N','T',
- 'R','A','N','T',' ','-','D','Z','L','I','B',' ','-','D','N','D',
- 'E','B','U','G','\0'
-};
+/*
+ * WARNING: do not edit!
+ * Generated by util/mkbuildinf.pl
+ *
+ * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
+ *
+ * Licensed under the OpenSSL license (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
+ */
+
+#define PLATFORM "platform: ios64-cross"
+#define DATE "built on: Wed Oct 20 15:59:29 2021 UTC"
+
+/*
+ * Generate compiler_flags as an array of individual characters. This is a
+ * workaround for the situation where CFLAGS gets too long for a C90 string
+ * literal
+ */
+static const char compiler_flags[] = {
+ 'c','o','m','p','i','l','e','r',':',' ','c','c',' ','-','f','P',
+ 'I','C',' ','-','a','r','c','h',' ','a','r','m','6','4',' ','-',
+ 'm','i','o','s','-','v','e','r','s','i','o','n','-','m','i','n',
+ '=','7','.','0','.','0',' ','-','f','n','o','-','c','o','m','m',
+ 'o','n',' ','-','i','s','y','s','r','o','o','t',' ','/','S','D',
+ 'K','s','/',' ','-','O','3',' ','-','i','s','y','s','r','o','o',
+ 't',' ','/','A','p','p','l','i','c','a','t','i','o','n','s','/',
+ 'X','c','o','d','e','.','a','p','p','/','C','o','n','t','e','n',
+ 't','s','/','D','e','v','e','l','o','p','e','r','/','P','l','a',
+ 't','f','o','r','m','s','/','i','P','h','o','n','e','O','S','.',
+ 'p','l','a','t','f','o','r','m','/','D','e','v','e','l','o','p',
+ 'e','r','/','S','D','K','s','/','i','P','h','o','n','e','O','S',
+ '.','s','d','k','/',' ','-','m','i','o','s','-','v','e','r','s',
+ 'i','o','n','-','m','i','n','=','9','.','0',' ','-','D','O','P',
+ 'E','N','S','S','L','_','P','I','C',' ','-','D','O','P','E','N',
+ 'S','S','L','_','C','P','U','I','D','_','O','B','J',' ','-','D',
+ 'O','P','E','N','S','S','L','_','B','N','_','A','S','M','_','M',
+ 'O','N','T',' ','-','D','S','H','A','1','_','A','S','M',' ','-',
+ 'D','S','H','A','2','5','6','_','A','S','M',' ','-','D','S','H',
+ 'A','5','1','2','_','A','S','M',' ','-','D','K','E','C','C','A',
+ 'K','1','6','0','0','_','A','S','M',' ','-','D','V','P','A','E',
+ 'S','_','A','S','M',' ','-','D','E','C','P','_','N','I','S','T',
+ 'Z','2','5','6','_','A','S','M',' ','-','D','P','O','L','Y','1',
+ '3','0','5','_','A','S','M',' ','-','D','_','R','E','E','N','T',
+ 'R','A','N','T',' ','-','D','Z','L','I','B',' ','-','D','N','D',
+ 'E','B','U','G','\0'
+};
diff --git a/contrib/libs/openssl/crypto/buildinf-ios-i386.h b/contrib/libs/openssl/crypto/buildinf-ios-i386.h
index a126e20154..987ce562c5 100644
--- a/contrib/libs/openssl/crypto/buildinf-ios-i386.h
+++ b/contrib/libs/openssl/crypto/buildinf-ios-i386.h
@@ -1,56 +1,56 @@
-/*
- * WARNING: do not edit!
- * Generated by util/mkbuildinf.pl
- *
- * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
- *
- * Licensed under the OpenSSL license (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
- */
-
-#define PLATFORM "platform: darwin-i386-cc"
-#define DATE "built on: Wed Oct 20 15:43:19 2021 UTC"
-
-/*
- * Generate compiler_flags as an array of individual characters. This is a
- * workaround for the situation where CFLAGS gets too long for a C90 string
- * literal
- */
-static const char compiler_flags[] = {
- 'c','o','m','p','i','l','e','r',':',' ','c','c',' ','-','f','P',
- 'I','C',' ','-','a','r','c','h',' ','i','3','8','6',' ','-','O',
- '3',' ','-','f','o','m','i','t','-','f','r','a','m','e','-','p',
- 'o','i','n','t','e','r',' ','-','i','s','y','s','r','o','o','t',
- ' ','/','A','p','p','l','i','c','a','t','i','o','n','s','/','X',
- 'c','o','d','e','.','a','p','p','/','C','o','n','t','e','n','t',
- 's','/','D','e','v','e','l','o','p','e','r','/','P','l','a','t',
- 'f','o','r','m','s','/','i','P','h','o','n','e','S','i','m','u',
- 'l','a','t','o','r','.','p','l','a','t','f','o','r','m','/','D',
- 'e','v','e','l','o','p','e','r','/','S','D','K','s','/','i','P',
- 'h','o','n','e','S','i','m','u','l','a','t','o','r','.','s','d',
- 'k','/',' ','-','m','i','o','s','-','s','i','m','u','l','a','t',
- 'o','r','-','v','e','r','s','i','o','n','-','m','i','n','=','1',
- '0','.','0',' ','-','D','L','_','E','N','D','I','A','N',' ','-',
- 'D','O','P','E','N','S','S','L','_','P','I','C',' ','-','D','O',
- 'P','E','N','S','S','L','_','C','P','U','I','D','_','O','B','J',
- ' ','-','D','O','P','E','N','S','S','L','_','B','N','_','A','S',
- 'M','_','P','A','R','T','_','W','O','R','D','S',' ','-','D','O',
- 'P','E','N','S','S','L','_','I','A','3','2','_','S','S','E','2',
- ' ','-','D','O','P','E','N','S','S','L','_','B','N','_','A','S',
- 'M','_','M','O','N','T',' ','-','D','O','P','E','N','S','S','L',
- '_','B','N','_','A','S','M','_','G','F','2','m',' ','-','D','S',
- 'H','A','1','_','A','S','M',' ','-','D','S','H','A','2','5','6',
- '_','A','S','M',' ','-','D','S','H','A','5','1','2','_','A','S',
- 'M',' ','-','D','R','C','4','_','A','S','M',' ','-','D','M','D',
- '5','_','A','S','M',' ','-','D','R','M','D','1','6','0','_','A',
- 'S','M',' ','-','D','A','E','S','N','I','_','A','S','M',' ','-',
- 'D','V','P','A','E','S','_','A','S','M',' ','-','D','W','H','I',
- 'R','L','P','O','O','L','_','A','S','M',' ','-','D','G','H','A',
- 'S','H','_','A','S','M',' ','-','D','E','C','P','_','N','I','S',
- 'T','Z','2','5','6','_','A','S','M',' ','-','D','P','O','L','Y',
- '1','3','0','5','_','A','S','M',' ','-','D','_','R','E','E','N',
- 'T','R','A','N','T',' ','-','D','Z','L','I','B',' ','-','D','N',
- 'D','E','B','U','G','\0'
-};
+/*
+ * WARNING: do not edit!
+ * Generated by util/mkbuildinf.pl
+ *
+ * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
+ *
+ * Licensed under the OpenSSL license (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
+ */
+
+#define PLATFORM "platform: darwin-i386-cc"
+#define DATE "built on: Wed Oct 20 15:43:19 2021 UTC"
+
+/*
+ * Generate compiler_flags as an array of individual characters. This is a
+ * workaround for the situation where CFLAGS gets too long for a C90 string
+ * literal
+ */
+static const char compiler_flags[] = {
+ 'c','o','m','p','i','l','e','r',':',' ','c','c',' ','-','f','P',
+ 'I','C',' ','-','a','r','c','h',' ','i','3','8','6',' ','-','O',
+ '3',' ','-','f','o','m','i','t','-','f','r','a','m','e','-','p',
+ 'o','i','n','t','e','r',' ','-','i','s','y','s','r','o','o','t',
+ ' ','/','A','p','p','l','i','c','a','t','i','o','n','s','/','X',
+ 'c','o','d','e','.','a','p','p','/','C','o','n','t','e','n','t',
+ 's','/','D','e','v','e','l','o','p','e','r','/','P','l','a','t',
+ 'f','o','r','m','s','/','i','P','h','o','n','e','S','i','m','u',
+ 'l','a','t','o','r','.','p','l','a','t','f','o','r','m','/','D',
+ 'e','v','e','l','o','p','e','r','/','S','D','K','s','/','i','P',
+ 'h','o','n','e','S','i','m','u','l','a','t','o','r','.','s','d',
+ 'k','/',' ','-','m','i','o','s','-','s','i','m','u','l','a','t',
+ 'o','r','-','v','e','r','s','i','o','n','-','m','i','n','=','1',
+ '0','.','0',' ','-','D','L','_','E','N','D','I','A','N',' ','-',
+ 'D','O','P','E','N','S','S','L','_','P','I','C',' ','-','D','O',
+ 'P','E','N','S','S','L','_','C','P','U','I','D','_','O','B','J',
+ ' ','-','D','O','P','E','N','S','S','L','_','B','N','_','A','S',
+ 'M','_','P','A','R','T','_','W','O','R','D','S',' ','-','D','O',
+ 'P','E','N','S','S','L','_','I','A','3','2','_','S','S','E','2',
+ ' ','-','D','O','P','E','N','S','S','L','_','B','N','_','A','S',
+ 'M','_','M','O','N','T',' ','-','D','O','P','E','N','S','S','L',
+ '_','B','N','_','A','S','M','_','G','F','2','m',' ','-','D','S',
+ 'H','A','1','_','A','S','M',' ','-','D','S','H','A','2','5','6',
+ '_','A','S','M',' ','-','D','S','H','A','5','1','2','_','A','S',
+ 'M',' ','-','D','R','C','4','_','A','S','M',' ','-','D','M','D',
+ '5','_','A','S','M',' ','-','D','R','M','D','1','6','0','_','A',
+ 'S','M',' ','-','D','A','E','S','N','I','_','A','S','M',' ','-',
+ 'D','V','P','A','E','S','_','A','S','M',' ','-','D','W','H','I',
+ 'R','L','P','O','O','L','_','A','S','M',' ','-','D','G','H','A',
+ 'S','H','_','A','S','M',' ','-','D','E','C','P','_','N','I','S',
+ 'T','Z','2','5','6','_','A','S','M',' ','-','D','P','O','L','Y',
+ '1','3','0','5','_','A','S','M',' ','-','D','_','R','E','E','N',
+ 'T','R','A','N','T',' ','-','D','Z','L','I','B',' ','-','D','N',
+ 'D','E','B','U','G','\0'
+};
diff --git a/contrib/libs/openssl/crypto/buildinf-ios-x86_64.h b/contrib/libs/openssl/crypto/buildinf-ios-x86_64.h
index fc2c212ce9..7f4a9378b5 100644
--- a/contrib/libs/openssl/crypto/buildinf-ios-x86_64.h
+++ b/contrib/libs/openssl/crypto/buildinf-ios-x86_64.h
@@ -1,55 +1,55 @@
-/*
- * WARNING: do not edit!
- * Generated by util/mkbuildinf.pl
- *
- * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
- *
- * Licensed under the OpenSSL license (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
- */
-
-#define PLATFORM "platform: darwin64-x86_64-cc"
-#define DATE "built on: Wed Oct 20 15:29:23 2021 UTC"
-
-/*
- * Generate compiler_flags as an array of individual characters. This is a
- * workaround for the situation where CFLAGS gets too long for a C90 string
- * literal
- */
-static const char compiler_flags[] = {
- 'c','o','m','p','i','l','e','r',':',' ','c','c',' ','-','f','P',
- 'I','C',' ','-','a','r','c','h',' ','x','8','6','_','6','4',' ',
- '-','O','3',' ','-','W','a','l','l',' ','-','i','s','y','s','r',
- 'o','o','t',' ','/','A','p','p','l','i','c','a','t','i','o','n',
- 's','/','X','c','o','d','e','.','a','p','p','/','C','o','n','t',
- 'e','n','t','s','/','D','e','v','e','l','o','p','e','r','/','P',
- 'l','a','t','f','o','r','m','s','/','i','P','h','o','n','e','S',
- 'i','m','u','l','a','t','o','r','.','p','l','a','t','f','o','r',
- 'm','/','D','e','v','e','l','o','p','e','r','/','S','D','K','s',
- '/','i','P','h','o','n','e','S','i','m','u','l','a','t','o','r',
- '.','s','d','k','/',' ','-','m','i','o','s','-','s','i','m','u',
- 'l','a','t','o','r','-','v','e','r','s','i','o','n','-','m','i',
- 'n','=','1','0','.','0',' ','-','D','L','_','E','N','D','I','A',
- 'N',' ','-','D','O','P','E','N','S','S','L','_','P','I','C',' ',
- '-','D','O','P','E','N','S','S','L','_','C','P','U','I','D','_',
- 'O','B','J',' ','-','D','O','P','E','N','S','S','L','_','I','A',
- '3','2','_','S','S','E','2',' ','-','D','O','P','E','N','S','S',
- 'L','_','B','N','_','A','S','M','_','M','O','N','T',' ','-','D',
- 'O','P','E','N','S','S','L','_','B','N','_','A','S','M','_','M',
- 'O','N','T','5',' ','-','D','O','P','E','N','S','S','L','_','B',
- 'N','_','A','S','M','_','G','F','2','m',' ','-','D','S','H','A',
- '1','_','A','S','M',' ','-','D','S','H','A','2','5','6','_','A',
- 'S','M',' ','-','D','S','H','A','5','1','2','_','A','S','M',' ',
- '-','D','K','E','C','C','A','K','1','6','0','0','_','A','S','M',
- ' ','-','D','R','C','4','_','A','S','M',' ','-','D','M','D','5',
- '_','A','S','M',' ','-','D','A','E','S','N','I','_','A','S','M',
- ' ','-','D','V','P','A','E','S','_','A','S','M',' ','-','D','G',
- 'H','A','S','H','_','A','S','M',' ','-','D','E','C','P','_','N',
- 'I','S','T','Z','2','5','6','_','A','S','M',' ','-','D','X','2',
- '5','5','1','9','_','A','S','M',' ','-','D','P','O','L','Y','1',
- '3','0','5','_','A','S','M',' ','-','D','_','R','E','E','N','T',
- 'R','A','N','T',' ','-','D','Z','L','I','B',' ','-','D','N','D',
- 'E','B','U','G','\0'
-};
+/*
+ * WARNING: do not edit!
+ * Generated by util/mkbuildinf.pl
+ *
+ * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
+ *
+ * Licensed under the OpenSSL license (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
+ */
+
+#define PLATFORM "platform: darwin64-x86_64-cc"
+#define DATE "built on: Wed Oct 20 15:29:23 2021 UTC"
+
+/*
+ * Generate compiler_flags as an array of individual characters. This is a
+ * workaround for the situation where CFLAGS gets too long for a C90 string
+ * literal
+ */
+static const char compiler_flags[] = {
+ 'c','o','m','p','i','l','e','r',':',' ','c','c',' ','-','f','P',
+ 'I','C',' ','-','a','r','c','h',' ','x','8','6','_','6','4',' ',
+ '-','O','3',' ','-','W','a','l','l',' ','-','i','s','y','s','r',
+ 'o','o','t',' ','/','A','p','p','l','i','c','a','t','i','o','n',
+ 's','/','X','c','o','d','e','.','a','p','p','/','C','o','n','t',
+ 'e','n','t','s','/','D','e','v','e','l','o','p','e','r','/','P',
+ 'l','a','t','f','o','r','m','s','/','i','P','h','o','n','e','S',
+ 'i','m','u','l','a','t','o','r','.','p','l','a','t','f','o','r',
+ 'm','/','D','e','v','e','l','o','p','e','r','/','S','D','K','s',
+ '/','i','P','h','o','n','e','S','i','m','u','l','a','t','o','r',
+ '.','s','d','k','/',' ','-','m','i','o','s','-','s','i','m','u',
+ 'l','a','t','o','r','-','v','e','r','s','i','o','n','-','m','i',
+ 'n','=','1','0','.','0',' ','-','D','L','_','E','N','D','I','A',
+ 'N',' ','-','D','O','P','E','N','S','S','L','_','P','I','C',' ',
+ '-','D','O','P','E','N','S','S','L','_','C','P','U','I','D','_',
+ 'O','B','J',' ','-','D','O','P','E','N','S','S','L','_','I','A',
+ '3','2','_','S','S','E','2',' ','-','D','O','P','E','N','S','S',
+ 'L','_','B','N','_','A','S','M','_','M','O','N','T',' ','-','D',
+ 'O','P','E','N','S','S','L','_','B','N','_','A','S','M','_','M',
+ 'O','N','T','5',' ','-','D','O','P','E','N','S','S','L','_','B',
+ 'N','_','A','S','M','_','G','F','2','m',' ','-','D','S','H','A',
+ '1','_','A','S','M',' ','-','D','S','H','A','2','5','6','_','A',
+ 'S','M',' ','-','D','S','H','A','5','1','2','_','A','S','M',' ',
+ '-','D','K','E','C','C','A','K','1','6','0','0','_','A','S','M',
+ ' ','-','D','R','C','4','_','A','S','M',' ','-','D','M','D','5',
+ '_','A','S','M',' ','-','D','A','E','S','N','I','_','A','S','M',
+ ' ','-','D','V','P','A','E','S','_','A','S','M',' ','-','D','G',
+ 'H','A','S','H','_','A','S','M',' ','-','D','E','C','P','_','N',
+ 'I','S','T','Z','2','5','6','_','A','S','M',' ','-','D','X','2',
+ '5','5','1','9','_','A','S','M',' ','-','D','P','O','L','Y','1',
+ '3','0','5','_','A','S','M',' ','-','D','_','R','E','E','N','T',
+ 'R','A','N','T',' ','-','D','Z','L','I','B',' ','-','D','N','D',
+ 'E','B','U','G','\0'
+};
diff --git a/contrib/libs/openssl/crypto/buildinf-linux.h b/contrib/libs/openssl/crypto/buildinf-linux.h
index d043c94746..b3f3abffd4 100644
--- a/contrib/libs/openssl/crypto/buildinf-linux.h
+++ b/contrib/libs/openssl/crypto/buildinf-linux.h
@@ -11,7 +11,7 @@
*/
#define PLATFORM "platform: linux-x86_64"
-#define DATE "built on: Tue Jan 1 00:00:00 1980 UTC"
+#define DATE "built on: Tue Jan 1 00:00:00 1980 UTC"
/*
* Generate compiler_flags as an array of individual characters. This is a
diff --git a/contrib/libs/openssl/crypto/buildinf-linux_aarch64.h b/contrib/libs/openssl/crypto/buildinf-linux_aarch64.h
index fd4008b03c..70e6a2ebed 100644
--- a/contrib/libs/openssl/crypto/buildinf-linux_aarch64.h
+++ b/contrib/libs/openssl/crypto/buildinf-linux_aarch64.h
@@ -11,7 +11,7 @@
*/
#define PLATFORM "platform: linux-aarch64"
-#define DATE "built on: Wed Oct 20 13:28:32 2021 UTC"
+#define DATE "built on: Wed Oct 20 13:28:32 2021 UTC"
/*
* Generate compiler_flags as an array of individual characters. This is a
@@ -19,29 +19,29 @@
* literal
*/
static const char compiler_flags[] = {
- 'c','o','m','p','i','l','e','r',':',' ','/','h','o','m','e','/',
- 'h','e','r','e','t','i','c','/','.','y','a','/','t','o','o','l',
- 's','/','v','4','/','2','3','4','3','3','1','6','0','3','6','/',
- 'b','i','n','/','c','l','a','n','g',' ','-','-','t','a','r','g',
- 'e','t','=','a','a','r','c','h','6','4','-','l','i','n','u','x',
- '-','g','n','u',' ','-','m','a','r','c','h','=','a','r','m','v',
- '8','a',' ','-','-','s','y','s','r','o','o','t','=','/','h','o',
- 'm','e','/','h','e','r','e','t','i','c','/','.','y','a','/','t',
- 'o','o','l','s','/','v','4','/','3','0','9','0','5','4','7','8',
- '1',' ','-','f','P','I','C',' ','-','p','t','h','r','e','a','d',
- ' ','-','W','a',',','-','-','n','o','e','x','e','c','s','t','a',
- 'c','k',' ','-','Q','u','n','u','s','e','d','-','a','r','g','u',
- 'm','e','n','t','s',' ','-','W','a','l','l',' ','-','O','3',' ',
- '-','D','O','P','E','N','S','S','L','_','U','S','E','_','N','O',
- 'D','E','L','E','T','E',' ','-','D','O','P','E','N','S','S','L',
- '_','P','I','C',' ','-','D','O','P','E','N','S','S','L','_','C',
- 'P','U','I','D','_','O','B','J',' ','-','D','O','P','E','N','S',
- 'S','L','_','B','N','_','A','S','M','_','M','O','N','T',' ','-',
- 'D','S','H','A','1','_','A','S','M',' ','-','D','S','H','A','2',
- '5','6','_','A','S','M',' ','-','D','S','H','A','5','1','2','_',
- 'A','S','M',' ','-','D','K','E','C','C','A','K','1','6','0','0',
- '_','A','S','M',' ','-','D','V','P','A','E','S','_','A','S','M',
- ' ','-','D','E','C','P','_','N','I','S','T','Z','2','5','6','_',
- 'A','S','M',' ','-','D','P','O','L','Y','1','3','0','5','_','A',
- 'S','M',' ','-','D','N','D','E','B','U','G','\0'
+ 'c','o','m','p','i','l','e','r',':',' ','/','h','o','m','e','/',
+ 'h','e','r','e','t','i','c','/','.','y','a','/','t','o','o','l',
+ 's','/','v','4','/','2','3','4','3','3','1','6','0','3','6','/',
+ 'b','i','n','/','c','l','a','n','g',' ','-','-','t','a','r','g',
+ 'e','t','=','a','a','r','c','h','6','4','-','l','i','n','u','x',
+ '-','g','n','u',' ','-','m','a','r','c','h','=','a','r','m','v',
+ '8','a',' ','-','-','s','y','s','r','o','o','t','=','/','h','o',
+ 'm','e','/','h','e','r','e','t','i','c','/','.','y','a','/','t',
+ 'o','o','l','s','/','v','4','/','3','0','9','0','5','4','7','8',
+ '1',' ','-','f','P','I','C',' ','-','p','t','h','r','e','a','d',
+ ' ','-','W','a',',','-','-','n','o','e','x','e','c','s','t','a',
+ 'c','k',' ','-','Q','u','n','u','s','e','d','-','a','r','g','u',
+ 'm','e','n','t','s',' ','-','W','a','l','l',' ','-','O','3',' ',
+ '-','D','O','P','E','N','S','S','L','_','U','S','E','_','N','O',
+ 'D','E','L','E','T','E',' ','-','D','O','P','E','N','S','S','L',
+ '_','P','I','C',' ','-','D','O','P','E','N','S','S','L','_','C',
+ 'P','U','I','D','_','O','B','J',' ','-','D','O','P','E','N','S',
+ 'S','L','_','B','N','_','A','S','M','_','M','O','N','T',' ','-',
+ 'D','S','H','A','1','_','A','S','M',' ','-','D','S','H','A','2',
+ '5','6','_','A','S','M',' ','-','D','S','H','A','5','1','2','_',
+ 'A','S','M',' ','-','D','K','E','C','C','A','K','1','6','0','0',
+ '_','A','S','M',' ','-','D','V','P','A','E','S','_','A','S','M',
+ ' ','-','D','E','C','P','_','N','I','S','T','Z','2','5','6','_',
+ 'A','S','M',' ','-','D','P','O','L','Y','1','3','0','5','_','A',
+ 'S','M',' ','-','D','N','D','E','B','U','G','\0'
};
diff --git a/contrib/libs/openssl/crypto/buildinf-osx.h b/contrib/libs/openssl/crypto/buildinf-osx.h
index 5c6746fff0..072aa34e8c 100644
--- a/contrib/libs/openssl/crypto/buildinf-osx.h
+++ b/contrib/libs/openssl/crypto/buildinf-osx.h
@@ -11,7 +11,7 @@
*/
#define PLATFORM "platform: darwin64-x86_64-cc"
-#define DATE "built on: Wed Oct 20 15:06:19 2021 UTC"
+#define DATE "built on: Wed Oct 20 15:06:19 2021 UTC"
/*
* Generate compiler_flags as an array of individual characters. This is a
@@ -19,27 +19,27 @@
* literal
*/
static const char compiler_flags[] = {
- 'c','o','m','p','i','l','e','r',':',' ','c','c',' ','-','f','P',
- 'I','C',' ','-','a','r','c','h',' ','x','8','6','_','6','4',' ',
- '-','O','3',' ','-','W','a','l','l',' ','-','D','L','_','E','N',
- 'D','I','A','N',' ','-','D','O','P','E','N','S','S','L','_','P',
- 'I','C',' ','-','D','O','P','E','N','S','S','L','_','C','P','U',
- 'I','D','_','O','B','J',' ','-','D','O','P','E','N','S','S','L',
- '_','I','A','3','2','_','S','S','E','2',' ','-','D','O','P','E',
- 'N','S','S','L','_','B','N','_','A','S','M','_','M','O','N','T',
+ 'c','o','m','p','i','l','e','r',':',' ','c','c',' ','-','f','P',
+ 'I','C',' ','-','a','r','c','h',' ','x','8','6','_','6','4',' ',
+ '-','O','3',' ','-','W','a','l','l',' ','-','D','L','_','E','N',
+ 'D','I','A','N',' ','-','D','O','P','E','N','S','S','L','_','P',
+ 'I','C',' ','-','D','O','P','E','N','S','S','L','_','C','P','U',
+ 'I','D','_','O','B','J',' ','-','D','O','P','E','N','S','S','L',
+ '_','I','A','3','2','_','S','S','E','2',' ','-','D','O','P','E',
+ 'N','S','S','L','_','B','N','_','A','S','M','_','M','O','N','T',
' ','-','D','O','P','E','N','S','S','L','_','B','N','_','A','S',
- 'M','_','M','O','N','T','5',' ','-','D','O','P','E','N','S','S',
- 'L','_','B','N','_','A','S','M','_','G','F','2','m',' ','-','D',
- 'S','H','A','1','_','A','S','M',' ','-','D','S','H','A','2','5',
- '6','_','A','S','M',' ','-','D','S','H','A','5','1','2','_','A',
- 'S','M',' ','-','D','K','E','C','C','A','K','1','6','0','0','_',
- 'A','S','M',' ','-','D','R','C','4','_','A','S','M',' ','-','D',
- 'M','D','5','_','A','S','M',' ','-','D','A','E','S','N','I','_',
- 'A','S','M',' ','-','D','V','P','A','E','S','_','A','S','M',' ',
- '-','D','G','H','A','S','H','_','A','S','M',' ','-','D','E','C',
- 'P','_','N','I','S','T','Z','2','5','6','_','A','S','M',' ','-',
- 'D','X','2','5','5','1','9','_','A','S','M',' ','-','D','P','O',
- 'L','Y','1','3','0','5','_','A','S','M',' ','-','D','_','R','E',
- 'E','N','T','R','A','N','T',' ','-','D','Z','L','I','B',' ','-',
- 'D','N','D','E','B','U','G','\0'
+ 'M','_','M','O','N','T','5',' ','-','D','O','P','E','N','S','S',
+ 'L','_','B','N','_','A','S','M','_','G','F','2','m',' ','-','D',
+ 'S','H','A','1','_','A','S','M',' ','-','D','S','H','A','2','5',
+ '6','_','A','S','M',' ','-','D','S','H','A','5','1','2','_','A',
+ 'S','M',' ','-','D','K','E','C','C','A','K','1','6','0','0','_',
+ 'A','S','M',' ','-','D','R','C','4','_','A','S','M',' ','-','D',
+ 'M','D','5','_','A','S','M',' ','-','D','A','E','S','N','I','_',
+ 'A','S','M',' ','-','D','V','P','A','E','S','_','A','S','M',' ',
+ '-','D','G','H','A','S','H','_','A','S','M',' ','-','D','E','C',
+ 'P','_','N','I','S','T','Z','2','5','6','_','A','S','M',' ','-',
+ 'D','X','2','5','5','1','9','_','A','S','M',' ','-','D','P','O',
+ 'L','Y','1','3','0','5','_','A','S','M',' ','-','D','_','R','E',
+ 'E','N','T','R','A','N','T',' ','-','D','Z','L','I','B',' ','-',
+ 'D','N','D','E','B','U','G','\0'
};
diff --git a/contrib/libs/openssl/crypto/buildinf-osx_arm64.h b/contrib/libs/openssl/crypto/buildinf-osx_arm64.h
index 93a163b584..fd92dc7cd8 100644
--- a/contrib/libs/openssl/crypto/buildinf-osx_arm64.h
+++ b/contrib/libs/openssl/crypto/buildinf-osx_arm64.h
@@ -1,37 +1,37 @@
-/*
- * WARNING: do not edit!
- * Generated by util/mkbuildinf.pl
- *
- * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
- *
- * Licensed under the OpenSSL license (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
- */
-
-#define PLATFORM "platform: darwin64-arm64-cc"
-#define DATE "built on: Tue Oct 19 19:00:58 2021 UTC"
-
-/*
- * Generate compiler_flags as an array of individual characters. This is a
- * workaround for the situation where CFLAGS gets too long for a C90 string
- * literal
- */
-static const char compiler_flags[] = {
- 'c','o','m','p','i','l','e','r',':',' ','c','c',' ','-','f','P',
- 'I','C',' ','-','a','r','c','h',' ','a','r','m','6','4',' ','-',
- 'O','3',' ','-','W','a','l','l',' ','-','D','L','_','E','N','D',
- 'I','A','N',' ','-','D','O','P','E','N','S','S','L','_','P','I',
- 'C',' ','-','D','O','P','E','N','S','S','L','_','C','P','U','I',
- 'D','_','O','B','J',' ','-','D','O','P','E','N','S','S','L','_',
- 'B','N','_','A','S','M','_','M','O','N','T',' ','-','D','S','H',
- 'A','1','_','A','S','M',' ','-','D','S','H','A','2','5','6','_',
- 'A','S','M',' ','-','D','S','H','A','5','1','2','_','A','S','M',
- ' ','-','D','K','E','C','C','A','K','1','6','0','0','_','A','S',
- 'M',' ','-','D','V','P','A','E','S','_','A','S','M',' ','-','D',
- 'E','C','P','_','N','I','S','T','Z','2','5','6','_','A','S','M',
- ' ','-','D','P','O','L','Y','1','3','0','5','_','A','S','M',' ',
- '-','D','_','R','E','E','N','T','R','A','N','T',' ','-','D','Z',
- 'L','I','B',' ','-','D','N','D','E','B','U','G','\0'
-};
+/*
+ * WARNING: do not edit!
+ * Generated by util/mkbuildinf.pl
+ *
+ * Copyright 2014-2017 The OpenSSL Project Authors. All Rights Reserved.
+ *
+ * Licensed under the OpenSSL license (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
+ */
+
+#define PLATFORM "platform: darwin64-arm64-cc"
+#define DATE "built on: Tue Oct 19 19:00:58 2021 UTC"
+
+/*
+ * Generate compiler_flags as an array of individual characters. This is a
+ * workaround for the situation where CFLAGS gets too long for a C90 string
+ * literal
+ */
+static const char compiler_flags[] = {
+ 'c','o','m','p','i','l','e','r',':',' ','c','c',' ','-','f','P',
+ 'I','C',' ','-','a','r','c','h',' ','a','r','m','6','4',' ','-',
+ 'O','3',' ','-','W','a','l','l',' ','-','D','L','_','E','N','D',
+ 'I','A','N',' ','-','D','O','P','E','N','S','S','L','_','P','I',
+ 'C',' ','-','D','O','P','E','N','S','S','L','_','C','P','U','I',
+ 'D','_','O','B','J',' ','-','D','O','P','E','N','S','S','L','_',
+ 'B','N','_','A','S','M','_','M','O','N','T',' ','-','D','S','H',
+ 'A','1','_','A','S','M',' ','-','D','S','H','A','2','5','6','_',
+ 'A','S','M',' ','-','D','S','H','A','5','1','2','_','A','S','M',
+ ' ','-','D','K','E','C','C','A','K','1','6','0','0','_','A','S',
+ 'M',' ','-','D','V','P','A','E','S','_','A','S','M',' ','-','D',
+ 'E','C','P','_','N','I','S','T','Z','2','5','6','_','A','S','M',
+ ' ','-','D','P','O','L','Y','1','3','0','5','_','A','S','M',' ',
+ '-','D','_','R','E','E','N','T','R','A','N','T',' ','-','D','Z',
+ 'L','I','B',' ','-','D','N','D','E','B','U','G','\0'
+};
diff --git a/contrib/libs/openssl/crypto/buildinf-win.h b/contrib/libs/openssl/crypto/buildinf-win.h
index cfafa985d7..e879a93f37 100644
--- a/contrib/libs/openssl/crypto/buildinf-win.h
+++ b/contrib/libs/openssl/crypto/buildinf-win.h
@@ -10,8 +10,8 @@
* https://www.openssl.org/source/license.html
*/
-#define PLATFORM "platform: VC-WIN64A-masm"
-#define DATE "built on: Wed Oct 20 16:49:54 2021 UTC"
+#define PLATFORM "platform: VC-WIN64A-masm"
+#define DATE "built on: Wed Oct 20 16:49:54 2021 UTC"
/*
* Generate compiler_flags as an array of individual characters. This is a
@@ -21,25 +21,25 @@
static const char compiler_flags[] = {
'c','o','m','p','i','l','e','r',':',' ','c','l',' ','/','Z','i',
' ','/','F','d','o','s','s','l','_','s','t','a','t','i','c','.',
- 'p','d','b',' ','/','G','s','0',' ','/','G','F',' ','/','G','y',
- ' ','/','M','D',' ','/','W','3',' ','/','w','d','4','0','9','0',
- ' ','/','n','o','l','o','g','o',' ','/','O','2',' ','-','D','L',
- '_','E','N','D','I','A','N',' ','-','D','O','P','E','N','S','S',
- 'L','_','P','I','C',' ','-','D','O','P','E','N','S','S','L','_',
- 'C','P','U','I','D','_','O','B','J',' ','-','D','O','P','E','N',
- 'S','S','L','_','I','A','3','2','_','S','S','E','2',' ','-','D',
- 'O','P','E','N','S','S','L','_','B','N','_','A','S','M','_','M',
- 'O','N','T',' ','-','D','O','P','E','N','S','S','L','_','B','N',
- '_','A','S','M','_','M','O','N','T','5',' ','-','D','O','P','E',
- 'N','S','S','L','_','B','N','_','A','S','M','_','G','F','2','m',
- ' ','-','D','S','H','A','1','_','A','S','M',' ','-','D','S','H',
- 'A','2','5','6','_','A','S','M',' ','-','D','S','H','A','5','1',
- '2','_','A','S','M',' ','-','D','K','E','C','C','A','K','1','6',
- '0','0','_','A','S','M',' ','-','D','R','C','4','_','A','S','M',
- ' ','-','D','M','D','5','_','A','S','M',' ','-','D','A','E','S',
- 'N','I','_','A','S','M',' ','-','D','V','P','A','E','S','_','A',
- 'S','M',' ','-','D','G','H','A','S','H','_','A','S','M',' ','-',
- 'D','E','C','P','_','N','I','S','T','Z','2','5','6','_','A','S',
- 'M',' ','-','D','X','2','5','5','1','9','_','A','S','M',' ','-',
- 'D','P','O','L','Y','1','3','0','5','_','A','S','M','\0'
+ 'p','d','b',' ','/','G','s','0',' ','/','G','F',' ','/','G','y',
+ ' ','/','M','D',' ','/','W','3',' ','/','w','d','4','0','9','0',
+ ' ','/','n','o','l','o','g','o',' ','/','O','2',' ','-','D','L',
+ '_','E','N','D','I','A','N',' ','-','D','O','P','E','N','S','S',
+ 'L','_','P','I','C',' ','-','D','O','P','E','N','S','S','L','_',
+ 'C','P','U','I','D','_','O','B','J',' ','-','D','O','P','E','N',
+ 'S','S','L','_','I','A','3','2','_','S','S','E','2',' ','-','D',
+ 'O','P','E','N','S','S','L','_','B','N','_','A','S','M','_','M',
+ 'O','N','T',' ','-','D','O','P','E','N','S','S','L','_','B','N',
+ '_','A','S','M','_','M','O','N','T','5',' ','-','D','O','P','E',
+ 'N','S','S','L','_','B','N','_','A','S','M','_','G','F','2','m',
+ ' ','-','D','S','H','A','1','_','A','S','M',' ','-','D','S','H',
+ 'A','2','5','6','_','A','S','M',' ','-','D','S','H','A','5','1',
+ '2','_','A','S','M',' ','-','D','K','E','C','C','A','K','1','6',
+ '0','0','_','A','S','M',' ','-','D','R','C','4','_','A','S','M',
+ ' ','-','D','M','D','5','_','A','S','M',' ','-','D','A','E','S',
+ 'N','I','_','A','S','M',' ','-','D','V','P','A','E','S','_','A',
+ 'S','M',' ','-','D','G','H','A','S','H','_','A','S','M',' ','-',
+ 'D','E','C','P','_','N','I','S','T','Z','2','5','6','_','A','S',
+ 'M',' ','-','D','X','2','5','5','1','9','_','A','S','M',' ','-',
+ 'D','P','O','L','Y','1','3','0','5','_','A','S','M','\0'
};
diff --git a/contrib/libs/openssl/crypto/buildinf.h b/contrib/libs/openssl/crypto/buildinf.h
index 7d5f8a3cd4..12b79013ca 100644
--- a/contrib/libs/openssl/crypto/buildinf.h
+++ b/contrib/libs/openssl/crypto/buildinf.h
@@ -1,27 +1,27 @@
-#if defined(__APPLE__) && defined(__IOS__) && defined(__i386__)
-# include "buildinf-ios-i386.h"
-#elif defined(__APPLE__) && defined(__IOS__) && defined(__x86_64__)
-# include "buildinf-ios-x86_64.h"
-#elif defined(__APPLE__) && defined(__IOS__) && defined(__aarch64__)
-# include "buildinf-ios-arm64.h"
-#elif defined(__APPLE__) && defined(__IOS__) && defined(__arm__)
-# include "buildinf-ios-arm.h"
-#elif defined(__APPLE__) && defined(__x86_64__)
+#if defined(__APPLE__) && defined(__IOS__) && defined(__i386__)
+# include "buildinf-ios-i386.h"
+#elif defined(__APPLE__) && defined(__IOS__) && defined(__x86_64__)
+# include "buildinf-ios-x86_64.h"
+#elif defined(__APPLE__) && defined(__IOS__) && defined(__aarch64__)
+# include "buildinf-ios-arm64.h"
+#elif defined(__APPLE__) && defined(__IOS__) && defined(__arm__)
+# include "buildinf-ios-arm.h"
+#elif defined(__APPLE__) && defined(__x86_64__)
# include "buildinf-osx.h"
-#elif defined(__APPLE__) && defined(__aarch64__)
-# include "buildinf-osx_arm64.h"
+#elif defined(__APPLE__) && defined(__aarch64__)
+# include "buildinf-osx_arm64.h"
#elif defined(__linux__) && defined(__aarch64__)
# include "buildinf-linux_aarch64.h"
#elif defined(_MSC_VER) && defined(_M_X64)
# include "buildinf-win.h"
-#elif defined(__ANDROID__) && defined(__x86_64__)
-# include "buildinf-android_x86_64.h"
-#elif defined(__ANDROID__) && defined(__i686__)
-# include "buildinf-android_x86.h"
-#elif defined(__ANDROID__) && defined(__aarch64__)
-# include "buildinf-android_arm64.h"
-#elif defined(__ANDROID__) && defined(__arm__)
-# include "buildinf-android_arm.h"
+#elif defined(__ANDROID__) && defined(__x86_64__)
+# include "buildinf-android_x86_64.h"
+#elif defined(__ANDROID__) && defined(__i686__)
+# include "buildinf-android_x86.h"
+#elif defined(__ANDROID__) && defined(__aarch64__)
+# include "buildinf-android_arm64.h"
+#elif defined(__ANDROID__) && defined(__arm__)
+# include "buildinf-android_arm.h"
#else
# include "buildinf-linux.h"
#endif
diff --git a/contrib/libs/openssl/crypto/cmac/cmac.c b/contrib/libs/openssl/crypto/cmac/cmac.c
index aaea26ecb6..1fac531016 100644
--- a/contrib/libs/openssl/crypto/cmac/cmac.c
+++ b/contrib/libs/openssl/crypto/cmac/cmac.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2010-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2010-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -116,18 +116,18 @@ int CMAC_Init(CMAC_CTX *ctx, const void *key, size_t keylen,
return 1;
}
/* Initialise context */
- if (cipher != NULL) {
- /* Ensure we can't use this ctx until we also have a key */
- ctx->nlast_block = -1;
- if (!EVP_EncryptInit_ex(ctx->cctx, cipher, impl, NULL, NULL))
- return 0;
- }
+ if (cipher != NULL) {
+ /* Ensure we can't use this ctx until we also have a key */
+ ctx->nlast_block = -1;
+ if (!EVP_EncryptInit_ex(ctx->cctx, cipher, impl, NULL, NULL))
+ return 0;
+ }
/* Non-NULL key means initialisation complete */
- if (key != NULL) {
+ if (key != NULL) {
int bl;
-
- /* If anything fails then ensure we can't use this ctx */
- ctx->nlast_block = -1;
+
+ /* If anything fails then ensure we can't use this ctx */
+ ctx->nlast_block = -1;
if (!EVP_CIPHER_CTX_cipher(ctx->cctx))
return 0;
if (!EVP_CIPHER_CTX_set_key_length(ctx->cctx, keylen))
@@ -135,7 +135,7 @@ int CMAC_Init(CMAC_CTX *ctx, const void *key, size_t keylen,
if (!EVP_EncryptInit_ex(ctx->cctx, NULL, NULL, key, zero_iv))
return 0;
bl = EVP_CIPHER_CTX_block_size(ctx->cctx);
- if (EVP_Cipher(ctx->cctx, ctx->tbl, zero_iv, bl) <= 0)
+ if (EVP_Cipher(ctx->cctx, ctx->tbl, zero_iv, bl) <= 0)
return 0;
make_kn(ctx->k1, ctx->tbl, bl);
make_kn(ctx->k2, ctx->k1, bl);
@@ -173,12 +173,12 @@ int CMAC_Update(CMAC_CTX *ctx, const void *in, size_t dlen)
return 1;
data += nleft;
/* Else not final block so encrypt it */
- if (EVP_Cipher(ctx->cctx, ctx->tbl, ctx->last_block, bl) <= 0)
+ if (EVP_Cipher(ctx->cctx, ctx->tbl, ctx->last_block, bl) <= 0)
return 0;
}
/* Encrypt all but one of the complete blocks left */
while (dlen > bl) {
- if (EVP_Cipher(ctx->cctx, ctx->tbl, data, bl) <= 0)
+ if (EVP_Cipher(ctx->cctx, ctx->tbl, data, bl) <= 0)
return 0;
dlen -= bl;
data += bl;
diff --git a/contrib/libs/openssl/crypto/cms/cms_lib.c b/contrib/libs/openssl/crypto/cms/cms_lib.c
index 9e57c9c590..be4c2c703f 100644
--- a/contrib/libs/openssl/crypto/cms/cms_lib.c
+++ b/contrib/libs/openssl/crypto/cms/cms_lib.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2008-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2008-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -92,13 +92,13 @@ BIO *CMS_dataInit(CMS_ContentInfo *cms, BIO *icont)
default:
CMSerr(CMS_F_CMS_DATAINIT, CMS_R_UNSUPPORTED_TYPE);
- goto err;
+ goto err;
}
if (cmsbio)
return BIO_push(cmsbio, cont);
-err:
+err:
if (!icont)
BIO_free(cont);
return NULL;
diff --git a/contrib/libs/openssl/crypto/cms/cms_sd.c b/contrib/libs/openssl/crypto/cms/cms_sd.c
index 53e271083f..3f2a782565 100644
--- a/contrib/libs/openssl/crypto/cms/cms_sd.c
+++ b/contrib/libs/openssl/crypto/cms/cms_sd.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2008-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2008-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -897,10 +897,10 @@ int CMS_add_simple_smimecap(STACK_OF(X509_ALGOR) **algs,
ASN1_INTEGER *key = NULL;
if (keysize > 0) {
key = ASN1_INTEGER_new();
- if (key == NULL || !ASN1_INTEGER_set(key, keysize)) {
- ASN1_INTEGER_free(key);
+ if (key == NULL || !ASN1_INTEGER_set(key, keysize)) {
+ ASN1_INTEGER_free(key);
return 0;
- }
+ }
}
alg = X509_ALGOR_new();
if (alg == NULL) {
diff --git a/contrib/libs/openssl/crypto/cms/cms_smime.c b/contrib/libs/openssl/crypto/cms/cms_smime.c
index c42534b4b6..6e7dbc4da1 100644
--- a/contrib/libs/openssl/crypto/cms/cms_smime.c
+++ b/contrib/libs/openssl/crypto/cms/cms_smime.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2008-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2008-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -341,7 +341,7 @@ int CMS_verify(CMS_ContentInfo *cms, STACK_OF(X509) *certs,
char *ptr;
long len;
len = BIO_get_mem_data(dcont, &ptr);
- tmpin = (len == 0) ? dcont : BIO_new_mem_buf(ptr, len);
+ tmpin = (len == 0) ? dcont : BIO_new_mem_buf(ptr, len);
if (tmpin == NULL) {
CMSerr(CMS_F_CMS_VERIFY, ERR_R_MALLOC_FAILURE);
goto err2;
diff --git a/contrib/libs/openssl/crypto/conf/conf_def.c b/contrib/libs/openssl/crypto/conf/conf_def.c
index a4a6382412..31c02cc49e 100644
--- a/contrib/libs/openssl/crypto/conf/conf_def.c
+++ b/contrib/libs/openssl/crypto/conf/conf_def.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -185,7 +185,7 @@ static int def_load_bio(CONF *conf, BIO *in, long *line)
BUF_MEM *buff = NULL;
char *s, *p, *end;
int again;
- int first_call = 1;
+ int first_call = 1;
long eline = 0;
char btmp[DECIMAL_SIZE(eline) + 1];
CONF_VALUE *v = NULL, *tv;
@@ -234,19 +234,19 @@ static int def_load_bio(CONF *conf, BIO *in, long *line)
BIO_gets(in, p, CONFBUFSIZE - 1);
p[CONFBUFSIZE - 1] = '\0';
ii = i = strlen(p);
- if (first_call) {
- /* Other BOMs imply unsupported multibyte encoding,
- * so don't strip them and let the error raise */
- const unsigned char utf8_bom[3] = {0xEF, 0xBB, 0xBF};
-
- if (i >= 3 && memcmp(p, utf8_bom, 3) == 0) {
- memmove(p, p + 3, i - 3);
- p[i - 3] = 0;
- i -= 3;
- ii -= 3;
- }
- first_call = 0;
- }
+ if (first_call) {
+ /* Other BOMs imply unsupported multibyte encoding,
+ * so don't strip them and let the error raise */
+ const unsigned char utf8_bom[3] = {0xEF, 0xBB, 0xBF};
+
+ if (i >= 3 && memcmp(p, utf8_bom, 3) == 0) {
+ memmove(p, p + 3, i - 3);
+ p[i - 3] = 0;
+ i -= 3;
+ ii -= 3;
+ }
+ first_call = 0;
+ }
if (i == 0 && !again) {
/* the currently processed BIO is at EOF */
BIO *parent;
@@ -390,13 +390,13 @@ static int def_load_bio(CONF *conf, BIO *in, long *line)
if (biosk == NULL) {
if ((biosk = sk_BIO_new_null()) == NULL) {
CONFerr(CONF_F_DEF_LOAD_BIO, ERR_R_MALLOC_FAILURE);
- BIO_free(next);
+ BIO_free(next);
goto err;
}
}
if (!sk_BIO_push(biosk, in)) {
CONFerr(CONF_F_DEF_LOAD_BIO, ERR_R_MALLOC_FAILURE);
- BIO_free(next);
+ BIO_free(next);
goto err;
}
/* continue with reading from the included BIO */
diff --git a/contrib/libs/openssl/crypto/conf/conf_def.h b/contrib/libs/openssl/crypto/conf/conf_def.h
index da2cf51a4a..1e4a03e10b 100644
--- a/contrib/libs/openssl/crypto/conf/conf_def.h
+++ b/contrib/libs/openssl/crypto/conf/conf_def.h
@@ -2,7 +2,7 @@
* WARNING: do not edit!
* Generated by crypto/conf/keysets.pl
*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
* Licensed under the OpenSSL license (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
diff --git a/contrib/libs/openssl/crypto/dh/dh_key.c b/contrib/libs/openssl/crypto/dh/dh_key.c
index 7ca0f956a2..117f2fa883 100644
--- a/contrib/libs/openssl/crypto/dh/dh_key.c
+++ b/contrib/libs/openssl/crypto/dh/dh_key.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -25,45 +25,45 @@ int DH_generate_key(DH *dh)
return dh->meth->generate_key(dh);
}
-/*-
- * NB: This function is inherently not constant time due to the
- * RFC 5246 (8.1.2) padding style that strips leading zero bytes.
- */
+/*-
+ * NB: This function is inherently not constant time due to the
+ * RFC 5246 (8.1.2) padding style that strips leading zero bytes.
+ */
int DH_compute_key(unsigned char *key, const BIGNUM *pub_key, DH *dh)
{
- int ret = 0, i;
- volatile size_t npad = 0, mask = 1;
-
- /* compute the key; ret is constant unless compute_key is external */
- if ((ret = dh->meth->compute_key(key, pub_key, dh)) <= 0)
- return ret;
-
- /* count leading zero bytes, yet still touch all bytes */
- for (i = 0; i < ret; i++) {
- mask &= !key[i];
- npad += mask;
- }
-
- /* unpad key */
- ret -= npad;
- /* key-dependent memory access, potentially leaking npad / ret */
- memmove(key, key + npad, ret);
- /* key-dependent memory access, potentially leaking npad / ret */
- memset(key + ret, 0, npad);
-
- return ret;
+ int ret = 0, i;
+ volatile size_t npad = 0, mask = 1;
+
+ /* compute the key; ret is constant unless compute_key is external */
+ if ((ret = dh->meth->compute_key(key, pub_key, dh)) <= 0)
+ return ret;
+
+ /* count leading zero bytes, yet still touch all bytes */
+ for (i = 0; i < ret; i++) {
+ mask &= !key[i];
+ npad += mask;
+ }
+
+ /* unpad key */
+ ret -= npad;
+ /* key-dependent memory access, potentially leaking npad / ret */
+ memmove(key, key + npad, ret);
+ /* key-dependent memory access, potentially leaking npad / ret */
+ memset(key + ret, 0, npad);
+
+ return ret;
}
int DH_compute_key_padded(unsigned char *key, const BIGNUM *pub_key, DH *dh)
{
int rv, pad;
-
- /* rv is constant unless compute_key is external */
+
+ /* rv is constant unless compute_key is external */
rv = dh->meth->compute_key(key, pub_key, dh);
if (rv <= 0)
return rv;
pad = BN_num_bytes(dh->p) - rv;
- /* pad is constant (zero) unless compute_key is external */
+ /* pad is constant (zero) unless compute_key is external */
if (pad > 0) {
memmove(key + pad, key, rv);
memset(key, 0, pad);
@@ -239,7 +239,7 @@ static int compute_key(unsigned char *key, const BIGNUM *pub_key, DH *dh)
goto err;
}
- ret = BN_bn2binpad(tmp, key, BN_num_bytes(dh->p));
+ ret = BN_bn2binpad(tmp, key, BN_num_bytes(dh->p));
err:
BN_CTX_end(ctx);
BN_CTX_free(ctx);
diff --git a/contrib/libs/openssl/crypto/dsa/dsa_prn.c b/contrib/libs/openssl/crypto/dsa/dsa_prn.c
index 396fc93330..070b881e1f 100644
--- a/contrib/libs/openssl/crypto/dsa/dsa_prn.c
+++ b/contrib/libs/openssl/crypto/dsa/dsa_prn.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2006-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2006-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -49,11 +49,11 @@ int DSA_print(BIO *bp, const DSA *x, int off)
EVP_PKEY *pk;
int ret;
pk = EVP_PKEY_new();
- if (pk == NULL)
+ if (pk == NULL)
return 0;
- ret = EVP_PKEY_set1_DSA(pk, (DSA *)x);
- if (ret)
- ret = EVP_PKEY_print_private(bp, pk, off, NULL);
+ ret = EVP_PKEY_set1_DSA(pk, (DSA *)x);
+ if (ret)
+ ret = EVP_PKEY_print_private(bp, pk, off, NULL);
EVP_PKEY_free(pk);
return ret;
}
@@ -63,11 +63,11 @@ int DSAparams_print(BIO *bp, const DSA *x)
EVP_PKEY *pk;
int ret;
pk = EVP_PKEY_new();
- if (pk == NULL)
+ if (pk == NULL)
return 0;
- ret = EVP_PKEY_set1_DSA(pk, (DSA *)x);
- if (ret)
- ret = EVP_PKEY_print_params(bp, pk, 4, NULL);
+ ret = EVP_PKEY_set1_DSA(pk, (DSA *)x);
+ if (ret)
+ ret = EVP_PKEY_print_params(bp, pk, 4, NULL);
EVP_PKEY_free(pk);
return ret;
}
diff --git a/contrib/libs/openssl/crypto/dso/dso_win32.c b/contrib/libs/openssl/crypto/dso/dso_win32.c
index b5765537cd..af1e559d76 100644
--- a/contrib/libs/openssl/crypto/dso/dso_win32.c
+++ b/contrib/libs/openssl/crypto/dso/dso_win32.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2000-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2000-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -565,8 +565,8 @@ static int win32_pathbyaddr(void *addr, char *path, int sz)
/* Enumerate the modules to find one which includes me. */
do {
- if ((size_t) addr >= (size_t) me32.modBaseAddr &&
- (size_t) addr < (size_t) (me32.modBaseAddr + me32.modBaseSize)) {
+ if ((size_t) addr >= (size_t) me32.modBaseAddr &&
+ (size_t) addr < (size_t) (me32.modBaseAddr + me32.modBaseSize)) {
(*close_snap) (hModuleSnap);
FreeLibrary(dll);
# ifdef _WIN32_WCE
diff --git a/contrib/libs/openssl/crypto/ec/ec2_oct.c b/contrib/libs/openssl/crypto/ec/ec2_oct.c
index f6eb36e2f8..788e6501fb 100644
--- a/contrib/libs/openssl/crypto/ec/ec2_oct.c
+++ b/contrib/libs/openssl/crypto/ec/ec2_oct.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2011-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2011-2021 The OpenSSL Project Authors. All Rights Reserved.
* Copyright (c) 2002, Oracle and/or its affiliates. All rights reserved
*
* Licensed under the OpenSSL license (the "License"). You may not use
@@ -247,21 +247,21 @@ int ec_GF2m_simple_oct2point(const EC_GROUP *group, EC_POINT *point,
ECerr(EC_F_EC_GF2M_SIMPLE_OCT2POINT, EC_R_BUFFER_TOO_SMALL);
return 0;
}
-
- /*
- * The first octet is the point converison octet PC, see X9.62, page 4
- * and section 4.4.2. It must be:
- * 0x00 for the point at infinity
- * 0x02 or 0x03 for compressed form
- * 0x04 for uncompressed form
- * 0x06 or 0x07 for hybrid form.
- * For compressed or hybrid forms, we store the last bit of buf[0] as
- * y_bit and clear it from buf[0] so as to obtain a POINT_CONVERSION_*.
- * We error if buf[0] contains any but the above values.
- */
- y_bit = buf[0] & 1;
- form = buf[0] & ~1U;
-
+
+ /*
+ * The first octet is the point converison octet PC, see X9.62, page 4
+ * and section 4.4.2. It must be:
+ * 0x00 for the point at infinity
+ * 0x02 or 0x03 for compressed form
+ * 0x04 for uncompressed form
+ * 0x06 or 0x07 for hybrid form.
+ * For compressed or hybrid forms, we store the last bit of buf[0] as
+ * y_bit and clear it from buf[0] so as to obtain a POINT_CONVERSION_*.
+ * We error if buf[0] contains any but the above values.
+ */
+ y_bit = buf[0] & 1;
+ form = buf[0] & ~1U;
+
if ((form != 0) && (form != POINT_CONVERSION_COMPRESSED)
&& (form != POINT_CONVERSION_UNCOMPRESSED)
&& (form != POINT_CONVERSION_HYBRID)) {
@@ -273,7 +273,7 @@ int ec_GF2m_simple_oct2point(const EC_GROUP *group, EC_POINT *point,
return 0;
}
- /* The point at infinity is represented by a single zero octet. */
+ /* The point at infinity is represented by a single zero octet. */
if (form == 0) {
if (len != 1) {
ECerr(EC_F_EC_GF2M_SIMPLE_OCT2POINT, EC_R_INVALID_ENCODING);
@@ -325,23 +325,23 @@ int ec_GF2m_simple_oct2point(const EC_GROUP *group, EC_POINT *point,
goto err;
}
if (form == POINT_CONVERSION_HYBRID) {
- /*
- * Check that the form in the encoding was set correctly
- * according to X9.62 4.4.2.a, 4(c), see also first paragraph
- * of X9.62, 4.4.1.b.
- */
- if (BN_is_zero(x)) {
- if (y_bit != 0) {
- ECerr(ERR_LIB_EC, EC_R_INVALID_ENCODING);
- goto err;
- }
- } else {
- if (!group->meth->field_div(group, yxi, y, x, ctx))
- goto err;
- if (y_bit != BN_is_odd(yxi)) {
- ECerr(ERR_LIB_EC, EC_R_INVALID_ENCODING);
- goto err;
- }
+ /*
+ * Check that the form in the encoding was set correctly
+ * according to X9.62 4.4.2.a, 4(c), see also first paragraph
+ * of X9.62, 4.4.1.b.
+ */
+ if (BN_is_zero(x)) {
+ if (y_bit != 0) {
+ ECerr(ERR_LIB_EC, EC_R_INVALID_ENCODING);
+ goto err;
+ }
+ } else {
+ if (!group->meth->field_div(group, yxi, y, x, ctx))
+ goto err;
+ if (y_bit != BN_is_odd(yxi)) {
+ ECerr(ERR_LIB_EC, EC_R_INVALID_ENCODING);
+ goto err;
+ }
}
}
diff --git a/contrib/libs/openssl/crypto/ec/ec_ameth.c b/contrib/libs/openssl/crypto/ec/ec_ameth.c
index ce224952df..5098bd7a66 100644
--- a/contrib/libs/openssl/crypto/ec/ec_ameth.c
+++ b/contrib/libs/openssl/crypto/ec/ec_ameth.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2006-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2006-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -23,7 +23,7 @@ static int ecdh_cms_decrypt(CMS_RecipientInfo *ri);
static int ecdh_cms_encrypt(CMS_RecipientInfo *ri);
#endif
-static int eckey_param2type(int *pptype, void **ppval, const EC_KEY *ec_key)
+static int eckey_param2type(int *pptype, void **ppval, const EC_KEY *ec_key)
{
const EC_GROUP *group;
int nid;
@@ -35,14 +35,14 @@ static int eckey_param2type(int *pptype, void **ppval, const EC_KEY *ec_key)
&& (nid = EC_GROUP_get_curve_name(group)))
/* we have a 'named curve' => just set the OID */
{
- ASN1_OBJECT *asn1obj = OBJ_nid2obj(nid);
-
- if (asn1obj == NULL || OBJ_length(asn1obj) == 0) {
- ASN1_OBJECT_free(asn1obj);
- ECerr(EC_F_ECKEY_PARAM2TYPE, EC_R_MISSING_OID);
- return 0;
- }
- *ppval = asn1obj;
+ ASN1_OBJECT *asn1obj = OBJ_nid2obj(nid);
+
+ if (asn1obj == NULL || OBJ_length(asn1obj) == 0) {
+ ASN1_OBJECT_free(asn1obj);
+ ECerr(EC_F_ECKEY_PARAM2TYPE, EC_R_MISSING_OID);
+ return 0;
+ }
+ *ppval = asn1obj;
*pptype = V_ASN1_OBJECT;
} else { /* explicit parameters */
@@ -50,17 +50,17 @@ static int eckey_param2type(int *pptype, void **ppval, const EC_KEY *ec_key)
pstr = ASN1_STRING_new();
if (pstr == NULL)
return 0;
-
- /*
- * The cast in the following line is intentional as the
- * `i2d_ECParameters` signature can't be constified (see discussion at
- * https://github.com/openssl/openssl/pull/9347 where related and
- * required constification backports were rejected).
- *
- * This cast should be safe anyway, because we can expect
- * `i2d_ECParameters()` to treat the first argument as if it was const.
- */
- pstr->length = i2d_ECParameters((EC_KEY *)ec_key, &pstr->data);
+
+ /*
+ * The cast in the following line is intentional as the
+ * `i2d_ECParameters` signature can't be constified (see discussion at
+ * https://github.com/openssl/openssl/pull/9347 where related and
+ * required constification backports were rejected).
+ *
+ * This cast should be safe anyway, because we can expect
+ * `i2d_ECParameters()` to treat the first argument as if it was const.
+ */
+ pstr->length = i2d_ECParameters((EC_KEY *)ec_key, &pstr->data);
if (pstr->length <= 0) {
ASN1_STRING_free(pstr);
ECerr(EC_F_ECKEY_PARAM2TYPE, ERR_R_EC_LIB);
@@ -74,7 +74,7 @@ static int eckey_param2type(int *pptype, void **ppval, const EC_KEY *ec_key)
static int eckey_pub_encode(X509_PUBKEY *pk, const EVP_PKEY *pkey)
{
- const EC_KEY *ec_key = pkey->pkey.ec;
+ const EC_KEY *ec_key = pkey->pkey.ec;
void *pval = NULL;
int ptype;
unsigned char *penc = NULL, *p;
diff --git a/contrib/libs/openssl/crypto/ec/ec_asn1.c b/contrib/libs/openssl/crypto/ec/ec_asn1.c
index 0ce6a7d231..c8ee1e6f17 100644
--- a/contrib/libs/openssl/crypto/ec/ec_asn1.c
+++ b/contrib/libs/openssl/crypto/ec/ec_asn1.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2002-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2002-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -137,12 +137,12 @@ struct ec_parameters_st {
ASN1_INTEGER *cofactor;
} /* ECPARAMETERS */ ;
-typedef enum {
- ECPKPARAMETERS_TYPE_NAMED = 0,
- ECPKPARAMETERS_TYPE_EXPLICIT,
- ECPKPARAMETERS_TYPE_IMPLICIT
-} ecpk_parameters_type_t;
-
+typedef enum {
+ ECPKPARAMETERS_TYPE_NAMED = 0,
+ ECPKPARAMETERS_TYPE_EXPLICIT,
+ ECPKPARAMETERS_TYPE_IMPLICIT
+} ecpk_parameters_type_t;
+
struct ecpk_parameters_st {
int type;
union {
@@ -541,10 +541,10 @@ ECPKPARAMETERS *EC_GROUP_get_ecpkparameters(const EC_GROUP *group,
return NULL;
}
} else {
- if (ret->type == ECPKPARAMETERS_TYPE_NAMED)
+ if (ret->type == ECPKPARAMETERS_TYPE_NAMED)
ASN1_OBJECT_free(ret->value.named_curve);
- else if (ret->type == ECPKPARAMETERS_TYPE_EXPLICIT
- && ret->value.parameters != NULL)
+ else if (ret->type == ECPKPARAMETERS_TYPE_EXPLICIT
+ && ret->value.parameters != NULL)
ECPARAMETERS_free(ret->value.parameters);
}
@@ -554,22 +554,22 @@ ECPKPARAMETERS *EC_GROUP_get_ecpkparameters(const EC_GROUP *group,
*/
tmp = EC_GROUP_get_curve_name(group);
if (tmp) {
- ASN1_OBJECT *asn1obj = OBJ_nid2obj(tmp);
-
- if (asn1obj == NULL || OBJ_length(asn1obj) == 0) {
- ASN1_OBJECT_free(asn1obj);
- ECerr(EC_F_EC_GROUP_GET_ECPKPARAMETERS, EC_R_MISSING_OID);
+ ASN1_OBJECT *asn1obj = OBJ_nid2obj(tmp);
+
+ if (asn1obj == NULL || OBJ_length(asn1obj) == 0) {
+ ASN1_OBJECT_free(asn1obj);
+ ECerr(EC_F_EC_GROUP_GET_ECPKPARAMETERS, EC_R_MISSING_OID);
ok = 0;
- } else {
- ret->type = ECPKPARAMETERS_TYPE_NAMED;
- ret->value.named_curve = asn1obj;
- }
+ } else {
+ ret->type = ECPKPARAMETERS_TYPE_NAMED;
+ ret->value.named_curve = asn1obj;
+ }
} else
/* we don't know the nid => ERROR */
ok = 0;
} else {
/* use the ECPARAMETERS structure */
- ret->type = ECPKPARAMETERS_TYPE_EXPLICIT;
+ ret->type = ECPKPARAMETERS_TYPE_EXPLICIT;
if ((ret->value.parameters =
EC_GROUP_get_ecparameters(group, NULL)) == NULL)
ok = 0;
@@ -761,10 +761,10 @@ EC_GROUP *EC_GROUP_new_from_ecparameters(const ECPARAMETERS *params)
ret->seed_len = params->curve->seed->length;
}
- if (params->order == NULL
- || params->base == NULL
- || params->base->data == NULL
- || params->base->length == 0) {
+ if (params->order == NULL
+ || params->base == NULL
+ || params->base->data == NULL
+ || params->base->length == 0) {
ECerr(EC_F_EC_GROUP_NEW_FROM_ECPARAMETERS, EC_R_ASN1_ERROR);
goto err;
}
@@ -911,8 +911,8 @@ EC_GROUP *EC_GROUP_new_from_ecpkparameters(const ECPKPARAMETERS *params)
return NULL;
}
- if (params->type == ECPKPARAMETERS_TYPE_NAMED) {
- /* the curve is given by an OID */
+ if (params->type == ECPKPARAMETERS_TYPE_NAMED) {
+ /* the curve is given by an OID */
tmp = OBJ_obj2nid(params->value.named_curve);
if ((ret = EC_GROUP_new_by_curve_name(tmp)) == NULL) {
ECerr(EC_F_EC_GROUP_NEW_FROM_ECPKPARAMETERS,
@@ -920,16 +920,16 @@ EC_GROUP *EC_GROUP_new_from_ecpkparameters(const ECPKPARAMETERS *params)
return NULL;
}
EC_GROUP_set_asn1_flag(ret, OPENSSL_EC_NAMED_CURVE);
- } else if (params->type == ECPKPARAMETERS_TYPE_EXPLICIT) {
- /* the parameters are given by an ECPARAMETERS structure */
+ } else if (params->type == ECPKPARAMETERS_TYPE_EXPLICIT) {
+ /* the parameters are given by an ECPARAMETERS structure */
ret = EC_GROUP_new_from_ecparameters(params->value.parameters);
if (!ret) {
ECerr(EC_F_EC_GROUP_NEW_FROM_ECPKPARAMETERS, ERR_R_EC_LIB);
return NULL;
}
EC_GROUP_set_asn1_flag(ret, OPENSSL_EC_EXPLICIT_CURVE);
- } else if (params->type == ECPKPARAMETERS_TYPE_IMPLICIT) {
- /* implicit parameters inherited from CA - unsupported */
+ } else if (params->type == ECPKPARAMETERS_TYPE_IMPLICIT) {
+ /* implicit parameters inherited from CA - unsupported */
return NULL;
} else {
ECerr(EC_F_EC_GROUP_NEW_FROM_ECPKPARAMETERS, EC_R_ASN1_ERROR);
@@ -959,9 +959,9 @@ EC_GROUP *d2i_ECPKParameters(EC_GROUP **a, const unsigned char **in, long len)
return NULL;
}
- if (params->type == ECPKPARAMETERS_TYPE_EXPLICIT)
- group->decoded_from_explicit_params = 1;
-
+ if (params->type == ECPKPARAMETERS_TYPE_EXPLICIT)
+ group->decoded_from_explicit_params = 1;
+
if (a) {
EC_GROUP_free(*a);
*a = group;
@@ -1013,9 +1013,9 @@ EC_KEY *d2i_ECPrivateKey(EC_KEY **a, const unsigned char **in, long len)
if (priv_key->parameters) {
EC_GROUP_free(ret->group);
ret->group = EC_GROUP_new_from_ecpkparameters(priv_key->parameters);
- if (ret->group != NULL
- && priv_key->parameters->type == ECPKPARAMETERS_TYPE_EXPLICIT)
- ret->group->decoded_from_explicit_params = 1;
+ if (ret->group != NULL
+ && priv_key->parameters->type == ECPKPARAMETERS_TYPE_EXPLICIT)
+ ret->group->decoded_from_explicit_params = 1;
}
if (ret->group == NULL) {
diff --git a/contrib/libs/openssl/crypto/ec/ec_err.c b/contrib/libs/openssl/crypto/ec/ec_err.c
index 61510018ae..bfe7422650 100644
--- a/contrib/libs/openssl/crypto/ec/ec_err.c
+++ b/contrib/libs/openssl/crypto/ec/ec_err.c
@@ -1,6 +1,6 @@
/*
* Generated by util/mkerr.pl DO NOT EDIT
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -341,7 +341,7 @@ static const ERR_STRING_DATA EC_str_reasons[] = {
{ERR_PACK(ERR_LIB_EC, 0, EC_R_LADDER_POST_FAILURE), "ladder post failure"},
{ERR_PACK(ERR_LIB_EC, 0, EC_R_LADDER_PRE_FAILURE), "ladder pre failure"},
{ERR_PACK(ERR_LIB_EC, 0, EC_R_LADDER_STEP_FAILURE), "ladder step failure"},
- {ERR_PACK(ERR_LIB_EC, 0, EC_R_MISSING_OID), "missing OID"},
+ {ERR_PACK(ERR_LIB_EC, 0, EC_R_MISSING_OID), "missing OID"},
{ERR_PACK(ERR_LIB_EC, 0, EC_R_MISSING_PARAMETERS), "missing parameters"},
{ERR_PACK(ERR_LIB_EC, 0, EC_R_MISSING_PRIVATE_KEY), "missing private key"},
{ERR_PACK(ERR_LIB_EC, 0, EC_R_NEED_NEW_SETUP_VALUES),
diff --git a/contrib/libs/openssl/crypto/ec/ec_key.c b/contrib/libs/openssl/crypto/ec/ec_key.c
index 152385490d..23efbd015c 100644
--- a/contrib/libs/openssl/crypto/ec/ec_key.c
+++ b/contrib/libs/openssl/crypto/ec/ec_key.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2002-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2002-2020 The OpenSSL Project Authors. All Rights Reserved.
* Copyright (c) 2002, Oracle and/or its affiliates. All rights reserved
*
* Licensed under the OpenSSL license (the "License"). You may not use
@@ -14,7 +14,7 @@
#include "internal/refcount.h"
#include <openssl/err.h>
#include <openssl/engine.h>
-#include "crypto/bn.h"
+#include "crypto/bn.h"
EC_KEY *EC_KEY_new(void)
{
@@ -417,86 +417,86 @@ const BIGNUM *EC_KEY_get0_private_key(const EC_KEY *key)
int EC_KEY_set_private_key(EC_KEY *key, const BIGNUM *priv_key)
{
- int fixed_top;
- const BIGNUM *order = NULL;
- BIGNUM *tmp_key = NULL;
-
+ int fixed_top;
+ const BIGNUM *order = NULL;
+ BIGNUM *tmp_key = NULL;
+
if (key->group == NULL || key->group->meth == NULL)
return 0;
-
- /*
- * Not only should key->group be set, but it should also be in a valid
- * fully initialized state.
- *
- * Specifically, to operate in constant time, we need that the group order
- * is set, as we use its length as the fixed public size of any scalar used
- * as an EC private key.
- */
- order = EC_GROUP_get0_order(key->group);
- if (order == NULL || BN_is_zero(order))
- return 0; /* This should never happen */
-
+
+ /*
+ * Not only should key->group be set, but it should also be in a valid
+ * fully initialized state.
+ *
+ * Specifically, to operate in constant time, we need that the group order
+ * is set, as we use its length as the fixed public size of any scalar used
+ * as an EC private key.
+ */
+ order = EC_GROUP_get0_order(key->group);
+ if (order == NULL || BN_is_zero(order))
+ return 0; /* This should never happen */
+
if (key->group->meth->set_private != NULL
&& key->group->meth->set_private(key, priv_key) == 0)
return 0;
if (key->meth->set_private != NULL
&& key->meth->set_private(key, priv_key) == 0)
return 0;
-
- /*
- * We should never leak the bit length of the secret scalar in the key,
- * so we always set the `BN_FLG_CONSTTIME` flag on the internal `BIGNUM`
- * holding the secret scalar.
- *
- * This is important also because `BN_dup()` (and `BN_copy()`) do not
- * propagate the `BN_FLG_CONSTTIME` flag from the source `BIGNUM`, and
- * this brings an extra risk of inadvertently losing the flag, even when
- * the caller specifically set it.
- *
- * The propagation has been turned on and off a few times in the past
- * years because in some conditions has shown unintended consequences in
- * some code paths, so at the moment we can't fix this in the BN layer.
- *
- * In `EC_KEY_set_private_key()` we can work around the propagation by
- * manually setting the flag after `BN_dup()` as we know for sure that
- * inside the EC module the `BN_FLG_CONSTTIME` is always treated
- * correctly and should not generate unintended consequences.
- *
- * Setting the BN_FLG_CONSTTIME flag alone is never enough, we also have
- * to preallocate the BIGNUM internal buffer to a fixed public size big
- * enough that operations performed during the processing never trigger
- * a realloc which would leak the size of the scalar through memory
- * accesses.
- *
- * Fixed Length
- * ------------
- *
- * The order of the large prime subgroup of the curve is our choice for
- * a fixed public size, as that is generally the upper bound for
- * generating a private key in EC cryptosystems and should fit all valid
- * secret scalars.
- *
- * For preallocating the BIGNUM storage we look at the number of "words"
- * required for the internal representation of the order, and we
- * preallocate 2 extra "words" in case any of the subsequent processing
- * might temporarily overflow the order length.
- */
- tmp_key = BN_dup(priv_key);
- if (tmp_key == NULL)
- return 0;
-
- BN_set_flags(tmp_key, BN_FLG_CONSTTIME);
-
- fixed_top = bn_get_top(order) + 2;
- if (bn_wexpand(tmp_key, fixed_top) == NULL) {
- BN_clear_free(tmp_key);
- return 0;
- }
-
+
+ /*
+ * We should never leak the bit length of the secret scalar in the key,
+ * so we always set the `BN_FLG_CONSTTIME` flag on the internal `BIGNUM`
+ * holding the secret scalar.
+ *
+ * This is important also because `BN_dup()` (and `BN_copy()`) do not
+ * propagate the `BN_FLG_CONSTTIME` flag from the source `BIGNUM`, and
+ * this brings an extra risk of inadvertently losing the flag, even when
+ * the caller specifically set it.
+ *
+ * The propagation has been turned on and off a few times in the past
+ * years because in some conditions has shown unintended consequences in
+ * some code paths, so at the moment we can't fix this in the BN layer.
+ *
+ * In `EC_KEY_set_private_key()` we can work around the propagation by
+ * manually setting the flag after `BN_dup()` as we know for sure that
+ * inside the EC module the `BN_FLG_CONSTTIME` is always treated
+ * correctly and should not generate unintended consequences.
+ *
+ * Setting the BN_FLG_CONSTTIME flag alone is never enough, we also have
+ * to preallocate the BIGNUM internal buffer to a fixed public size big
+ * enough that operations performed during the processing never trigger
+ * a realloc which would leak the size of the scalar through memory
+ * accesses.
+ *
+ * Fixed Length
+ * ------------
+ *
+ * The order of the large prime subgroup of the curve is our choice for
+ * a fixed public size, as that is generally the upper bound for
+ * generating a private key in EC cryptosystems and should fit all valid
+ * secret scalars.
+ *
+ * For preallocating the BIGNUM storage we look at the number of "words"
+ * required for the internal representation of the order, and we
+ * preallocate 2 extra "words" in case any of the subsequent processing
+ * might temporarily overflow the order length.
+ */
+ tmp_key = BN_dup(priv_key);
+ if (tmp_key == NULL)
+ return 0;
+
+ BN_set_flags(tmp_key, BN_FLG_CONSTTIME);
+
+ fixed_top = bn_get_top(order) + 2;
+ if (bn_wexpand(tmp_key, fixed_top) == NULL) {
+ BN_clear_free(tmp_key);
+ return 0;
+ }
+
BN_clear_free(key->priv_key);
- key->priv_key = tmp_key;
-
- return 1;
+ key->priv_key = tmp_key;
+
+ return 1;
}
const EC_POINT *EC_KEY_get0_public_key(const EC_KEY *key)
@@ -564,13 +564,13 @@ void EC_KEY_clear_flags(EC_KEY *key, int flags)
key->flags &= ~flags;
}
-int EC_KEY_decoded_from_explicit_params(const EC_KEY *key)
-{
- if (key == NULL || key->group == NULL)
- return -1;
- return key->group->decoded_from_explicit_params;
-}
-
+int EC_KEY_decoded_from_explicit_params(const EC_KEY *key)
+{
+ if (key == NULL || key->group == NULL)
+ return -1;
+ return key->group->decoded_from_explicit_params;
+}
+
size_t EC_KEY_key2buf(const EC_KEY *key, point_conversion_form_t form,
unsigned char **pbuf, BN_CTX *ctx)
{
diff --git a/contrib/libs/openssl/crypto/ec/ec_lib.c b/contrib/libs/openssl/crypto/ec/ec_lib.c
index ba4225d975..08db89fcee 100644
--- a/contrib/libs/openssl/crypto/ec/ec_lib.c
+++ b/contrib/libs/openssl/crypto/ec/ec_lib.c
@@ -211,7 +211,7 @@ int EC_GROUP_copy(EC_GROUP *dest, const EC_GROUP *src)
dest->asn1_flag = src->asn1_flag;
dest->asn1_form = src->asn1_form;
- dest->decoded_from_explicit_params = src->decoded_from_explicit_params;
+ dest->decoded_from_explicit_params = src->decoded_from_explicit_params;
if (src->seed) {
OPENSSL_free(dest->seed);
diff --git a/contrib/libs/openssl/crypto/ec/ec_local.h b/contrib/libs/openssl/crypto/ec/ec_local.h
index 85b9124a18..64725a9c92 100644
--- a/contrib/libs/openssl/crypto/ec/ec_local.h
+++ b/contrib/libs/openssl/crypto/ec/ec_local.h
@@ -1,5 +1,5 @@
/*
- * Copyright 2001-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2001-2020 The OpenSSL Project Authors. All Rights Reserved.
* Copyright (c) 2002, Oracle and/or its affiliates. All rights reserved
*
* Licensed under the OpenSSL license (the "License"). You may not use
@@ -209,8 +209,8 @@ struct ec_group_st {
BIGNUM *order, *cofactor;
int curve_name; /* optional NID for named curve */
int asn1_flag; /* flag to control the asn1 encoding */
- int decoded_from_explicit_params; /* set if decoded from explicit
- * curve parameters encoding */
+ int decoded_from_explicit_params; /* set if decoded from explicit
+ * curve parameters encoding */
point_conversion_form_t asn1_form;
unsigned char *seed; /* optional seed for parameters (appears in
* ASN1) */
diff --git a/contrib/libs/openssl/crypto/ec/ecp_nistp224.c b/contrib/libs/openssl/crypto/ec/ecp_nistp224.c
index c647aecd4d..6f7d66c8be 100644
--- a/contrib/libs/openssl/crypto/ec/ecp_nistp224.c
+++ b/contrib/libs/openssl/crypto/ec/ecp_nistp224.c
@@ -72,7 +72,7 @@ typedef uint64_t u64;
*/
typedef uint64_t limb;
-typedef uint64_t limb_aX __attribute((__aligned__(1)));
+typedef uint64_t limb_aX __attribute((__aligned__(1)));
typedef uint128_t widelimb;
typedef limb felem[4];
@@ -308,10 +308,10 @@ const EC_METHOD *EC_GFp_nistp224_method(void)
*/
static void bin28_to_felem(felem out, const u8 in[28])
{
- out[0] = *((const limb *)(in)) & 0x00ffffffffffffff;
- out[1] = (*((const limb_aX *)(in + 7))) & 0x00ffffffffffffff;
- out[2] = (*((const limb_aX *)(in + 14))) & 0x00ffffffffffffff;
- out[3] = (*((const limb_aX *)(in + 20))) >> 8;
+ out[0] = *((const limb *)(in)) & 0x00ffffffffffffff;
+ out[1] = (*((const limb_aX *)(in + 7))) & 0x00ffffffffffffff;
+ out[2] = (*((const limb_aX *)(in + 14))) & 0x00ffffffffffffff;
+ out[3] = (*((const limb_aX *)(in + 20))) >> 8;
}
static void felem_to_bin28(u8 out[28], const felem in)
diff --git a/contrib/libs/openssl/crypto/ec/ecp_nistp521.c b/contrib/libs/openssl/crypto/ec/ecp_nistp521.c
index 9ee667fb28..08b3278729 100644
--- a/contrib/libs/openssl/crypto/ec/ecp_nistp521.c
+++ b/contrib/libs/openssl/crypto/ec/ecp_nistp521.c
@@ -128,7 +128,7 @@ static const felem_bytearray nistp521_curve_params[5] = {
# define NLIMBS 9
typedef uint64_t limb;
-typedef limb limb_aX __attribute((__aligned__(1)));
+typedef limb limb_aX __attribute((__aligned__(1)));
typedef limb felem[NLIMBS];
typedef uint128_t largefelem[NLIMBS];
@@ -142,14 +142,14 @@ static const limb bottom58bits = 0x3ffffffffffffff;
static void bin66_to_felem(felem out, const u8 in[66])
{
out[0] = (*((limb *) & in[0])) & bottom58bits;
- out[1] = (*((limb_aX *) & in[7]) >> 2) & bottom58bits;
- out[2] = (*((limb_aX *) & in[14]) >> 4) & bottom58bits;
- out[3] = (*((limb_aX *) & in[21]) >> 6) & bottom58bits;
- out[4] = (*((limb_aX *) & in[29])) & bottom58bits;
- out[5] = (*((limb_aX *) & in[36]) >> 2) & bottom58bits;
- out[6] = (*((limb_aX *) & in[43]) >> 4) & bottom58bits;
- out[7] = (*((limb_aX *) & in[50]) >> 6) & bottom58bits;
- out[8] = (*((limb_aX *) & in[58])) & bottom57bits;
+ out[1] = (*((limb_aX *) & in[7]) >> 2) & bottom58bits;
+ out[2] = (*((limb_aX *) & in[14]) >> 4) & bottom58bits;
+ out[3] = (*((limb_aX *) & in[21]) >> 6) & bottom58bits;
+ out[4] = (*((limb_aX *) & in[29])) & bottom58bits;
+ out[5] = (*((limb_aX *) & in[36]) >> 2) & bottom58bits;
+ out[6] = (*((limb_aX *) & in[43]) >> 4) & bottom58bits;
+ out[7] = (*((limb_aX *) & in[50]) >> 6) & bottom58bits;
+ out[8] = (*((limb_aX *) & in[58])) & bottom57bits;
}
/*
@@ -160,14 +160,14 @@ static void felem_to_bin66(u8 out[66], const felem in)
{
memset(out, 0, 66);
(*((limb *) & out[0])) = in[0];
- (*((limb_aX *) & out[7])) |= in[1] << 2;
- (*((limb_aX *) & out[14])) |= in[2] << 4;
- (*((limb_aX *) & out[21])) |= in[3] << 6;
- (*((limb_aX *) & out[29])) = in[4];
- (*((limb_aX *) & out[36])) |= in[5] << 2;
- (*((limb_aX *) & out[43])) |= in[6] << 4;
- (*((limb_aX *) & out[50])) |= in[7] << 6;
- (*((limb_aX *) & out[58])) = in[8];
+ (*((limb_aX *) & out[7])) |= in[1] << 2;
+ (*((limb_aX *) & out[14])) |= in[2] << 4;
+ (*((limb_aX *) & out[21])) |= in[3] << 6;
+ (*((limb_aX *) & out[29])) = in[4];
+ (*((limb_aX *) & out[36])) |= in[5] << 2;
+ (*((limb_aX *) & out[43])) |= in[6] << 4;
+ (*((limb_aX *) & out[50])) |= in[7] << 6;
+ (*((limb_aX *) & out[58])) = in[8];
}
/* BN_to_felem converts an OpenSSL BIGNUM into an felem */
diff --git a/contrib/libs/openssl/crypto/ec/ecp_nistz256.c b/contrib/libs/openssl/crypto/ec/ecp_nistz256.c
index 8309b34923..4c4839cc13 100644
--- a/contrib/libs/openssl/crypto/ec/ecp_nistz256.c
+++ b/contrib/libs/openssl/crypto/ec/ecp_nistz256.c
@@ -1019,8 +1019,8 @@ __owur static int ecp_nistz256_points_mul(const EC_GROUP *group,
}
if (preComputedTable) {
- BN_ULONG infty;
-
+ BN_ULONG infty;
+
if ((BN_num_bits(scalar) > 256)
|| BN_is_negative(scalar)) {
if ((tmp_scalar = BN_CTX_get(ctx)) == NULL)
@@ -1052,58 +1052,58 @@ __owur static int ecp_nistz256_points_mul(const EC_GROUP *group,
for (; i < 33; i++)
p_str[i] = 0;
- /* First window */
- wvalue = (p_str[0] << 1) & mask;
- idx += window_size;
-
- wvalue = _booth_recode_w7(wvalue);
-
- ecp_nistz256_gather_w7(&p.a, preComputedTable[0],
- wvalue >> 1);
-
- ecp_nistz256_neg(p.p.Z, p.p.Y);
- copy_conditional(p.p.Y, p.p.Z, wvalue & 1);
-
- /*
- * Since affine infinity is encoded as (0,0) and
- * Jacobian is (,,0), we need to harmonize them
- * by assigning "one" or zero to Z.
- */
- infty = (p.p.X[0] | p.p.X[1] | p.p.X[2] | p.p.X[3] |
- p.p.Y[0] | p.p.Y[1] | p.p.Y[2] | p.p.Y[3]);
- if (P256_LIMBS == 8)
- infty |= (p.p.X[4] | p.p.X[5] | p.p.X[6] | p.p.X[7] |
- p.p.Y[4] | p.p.Y[5] | p.p.Y[6] | p.p.Y[7]);
-
- infty = 0 - is_zero(infty);
- infty = ~infty;
-
- p.p.Z[0] = ONE[0] & infty;
- p.p.Z[1] = ONE[1] & infty;
- p.p.Z[2] = ONE[2] & infty;
- p.p.Z[3] = ONE[3] & infty;
- if (P256_LIMBS == 8) {
- p.p.Z[4] = ONE[4] & infty;
- p.p.Z[5] = ONE[5] & infty;
- p.p.Z[6] = ONE[6] & infty;
- p.p.Z[7] = ONE[7] & infty;
- }
-
- for (i = 1; i < 37; i++) {
- unsigned int off = (idx - 1) / 8;
- wvalue = p_str[off] | p_str[off + 1] << 8;
- wvalue = (wvalue >> ((idx - 1) % 8)) & mask;
- idx += window_size;
-
- wvalue = _booth_recode_w7(wvalue);
-
- ecp_nistz256_gather_w7(&t.a,
- preComputedTable[i], wvalue >> 1);
-
- ecp_nistz256_neg(t.p.Z, t.a.Y);
- copy_conditional(t.a.Y, t.p.Z, wvalue & 1);
-
- ecp_nistz256_point_add_affine(&p.p, &p.p, &t.a);
+ /* First window */
+ wvalue = (p_str[0] << 1) & mask;
+ idx += window_size;
+
+ wvalue = _booth_recode_w7(wvalue);
+
+ ecp_nistz256_gather_w7(&p.a, preComputedTable[0],
+ wvalue >> 1);
+
+ ecp_nistz256_neg(p.p.Z, p.p.Y);
+ copy_conditional(p.p.Y, p.p.Z, wvalue & 1);
+
+ /*
+ * Since affine infinity is encoded as (0,0) and
+ * Jacobian is (,,0), we need to harmonize them
+ * by assigning "one" or zero to Z.
+ */
+ infty = (p.p.X[0] | p.p.X[1] | p.p.X[2] | p.p.X[3] |
+ p.p.Y[0] | p.p.Y[1] | p.p.Y[2] | p.p.Y[3]);
+ if (P256_LIMBS == 8)
+ infty |= (p.p.X[4] | p.p.X[5] | p.p.X[6] | p.p.X[7] |
+ p.p.Y[4] | p.p.Y[5] | p.p.Y[6] | p.p.Y[7]);
+
+ infty = 0 - is_zero(infty);
+ infty = ~infty;
+
+ p.p.Z[0] = ONE[0] & infty;
+ p.p.Z[1] = ONE[1] & infty;
+ p.p.Z[2] = ONE[2] & infty;
+ p.p.Z[3] = ONE[3] & infty;
+ if (P256_LIMBS == 8) {
+ p.p.Z[4] = ONE[4] & infty;
+ p.p.Z[5] = ONE[5] & infty;
+ p.p.Z[6] = ONE[6] & infty;
+ p.p.Z[7] = ONE[7] & infty;
+ }
+
+ for (i = 1; i < 37; i++) {
+ unsigned int off = (idx - 1) / 8;
+ wvalue = p_str[off] | p_str[off + 1] << 8;
+ wvalue = (wvalue >> ((idx - 1) % 8)) & mask;
+ idx += window_size;
+
+ wvalue = _booth_recode_w7(wvalue);
+
+ ecp_nistz256_gather_w7(&t.a,
+ preComputedTable[i], wvalue >> 1);
+
+ ecp_nistz256_neg(t.p.Z, t.a.Y);
+ copy_conditional(t.a.Y, t.p.Z, wvalue & 1);
+
+ ecp_nistz256_point_add_affine(&p.p, &p.p, &t.a);
}
} else {
p_is_infinity = 1;
diff --git a/contrib/libs/openssl/crypto/engine/README b/contrib/libs/openssl/crypto/engine/README
index 4984d4d65d..0f8a8fbde4 100644
--- a/contrib/libs/openssl/crypto/engine/README
+++ b/contrib/libs/openssl/crypto/engine/README
@@ -1,211 +1,211 @@
-Notes: 2001-09-24
------------------
-
-This "description" (if one chooses to call it that) needed some major updating
-so here goes. This update addresses a change being made at the same time to
-OpenSSL, and it pretty much completely restructures the underlying mechanics of
-the "ENGINE" code. So it serves a double purpose of being a "ENGINE internals
-for masochists" document *and* a rather extensive commit log message. (I'd get
-lynched for sticking all this in CHANGES or the commit mails :-).
-
-ENGINE_TABLE underlies this restructuring, as described in the internal header
-"eng_local.h", implemented in eng_table.c, and used in each of the "class" files;
-tb_rsa.c, tb_dsa.c, etc.
-
-However, "EVP_CIPHER" underlies the motivation and design of ENGINE_TABLE so
-I'll mention a bit about that first. EVP_CIPHER (and most of this applies
-equally to EVP_MD for digests) is both a "method" and a algorithm/mode
-identifier that, in the current API, "lingers". These cipher description +
-implementation structures can be defined or obtained directly by applications,
-or can be loaded "en masse" into EVP storage so that they can be catalogued and
-searched in various ways, ie. two ways of encrypting with the "des_cbc"
-algorithm/mode pair are;
-
-(i) directly;
- const EVP_CIPHER *cipher = EVP_des_cbc();
- EVP_EncryptInit(&ctx, cipher, key, iv);
- [ ... use EVP_EncryptUpdate() and EVP_EncryptFinal() ...]
-
-(ii) indirectly;
- OpenSSL_add_all_ciphers();
- cipher = EVP_get_cipherbyname("des_cbc");
- EVP_EncryptInit(&ctx, cipher, key, iv);
- [ ... etc ... ]
-
-The latter is more generally used because it also allows ciphers/digests to be
-looked up based on other identifiers which can be useful for automatic cipher
-selection, eg. in SSL/TLS, or by user-controllable configuration.
-
-The important point about this is that EVP_CIPHER definitions and structures are
-passed around with impunity and there is no safe way, without requiring massive
-rewrites of many applications, to assume that EVP_CIPHERs can be reference
-counted. One an EVP_CIPHER is exposed to the caller, neither it nor anything it
-comes from can "safely" be destroyed. Unless of course the way of getting to
-such ciphers is via entirely distinct API calls that didn't exist before.
-However existing API usage cannot be made to understand when an EVP_CIPHER
-pointer, that has been passed to the caller, is no longer being used.
-
-The other problem with the existing API w.r.t. to hooking EVP_CIPHER support
-into ENGINE is storage - the OBJ_NAME-based storage used by EVP to register
-ciphers simultaneously registers cipher *types* and cipher *implementations* -
-they are effectively the same thing, an "EVP_CIPHER" pointer. The problem with
-hooking in ENGINEs is that multiple ENGINEs may implement the same ciphers. The
-solution is necessarily that ENGINE-provided ciphers simply are not registered,
-stored, or exposed to the caller in the same manner as existing ciphers. This is
-especially necessary considering the fact ENGINE uses reference counts to allow
-for cleanup, modularity, and DSO support - yet EVP_CIPHERs, as exposed to
-callers in the current API, support no such controls.
-
-Another sticking point for integrating cipher support into ENGINE is linkage.
-Already there is a problem with the way ENGINE supports RSA, DSA, etc whereby
-they are available *because* they're part of a giant ENGINE called "openssl".
-Ie. all implementations *have* to come from an ENGINE, but we get round that by
-having a giant ENGINE with all the software support encapsulated. This creates
-linker hassles if nothing else - linking a 1-line application that calls 2 basic
-RSA functions (eg. "RSA_free(RSA_new());") will result in large quantities of
-ENGINE code being linked in *and* because of that DSA, DH, and RAND also. If we
-continue with this approach for EVP_CIPHER support (even if it *was* possible)
-we would lose our ability to link selectively by selectively loading certain
-implementations of certain functionality. Touching any part of any kind of
-crypto would result in massive static linkage of everything else. So the
-solution is to change the way ENGINE feeds existing "classes", ie. how the
-hooking to ENGINE works from RSA, DSA, DH, RAND, as well as adding new hooking
-for EVP_CIPHER, and EVP_MD.
-
-The way this is now being done is by mostly reverting back to how things used to
-work prior to ENGINE :-). Ie. RSA now has a "RSA_METHOD" pointer again - this
-was previously replaced by an "ENGINE" pointer and all RSA code that required
-the RSA_METHOD would call ENGINE_get_RSA() each time on its ENGINE handle to
-temporarily get and use the ENGINE's RSA implementation. Apart from being more
-efficient, switching back to each RSA having an RSA_METHOD pointer also allows
-us to conceivably operate with *no* ENGINE. As we'll see, this removes any need
-for a fallback ENGINE that encapsulates default implementations - we can simply
-have our RSA structure pointing its RSA_METHOD pointer to the software
-implementation and have its ENGINE pointer set to NULL.
-
-A look at the EVP_CIPHER hooking is most explanatory, the RSA, DSA (etc) cases
-turn out to be degenerate forms of the same thing. The EVP storage of ciphers,
-and the existing EVP API functions that return "software" implementations and
-descriptions remain untouched. However, the storage takes more meaning in terms
-of "cipher description" and less meaning in terms of "implementation". When an
-EVP_CIPHER_CTX is actually initialised with an EVP_CIPHER method and is about to
-begin en/decryption, the hooking to ENGINE comes into play. What happens is that
-cipher-specific ENGINE code is asked for an ENGINE pointer (a functional
-reference) for any ENGINE that is registered to perform the algo/mode that the
-provided EVP_CIPHER structure represents. Under normal circumstances, that
-ENGINE code will return NULL because no ENGINEs will have had any cipher
-implementations *registered*. As such, a NULL ENGINE pointer is stored in the
-EVP_CIPHER_CTX context, and the EVP_CIPHER structure is left hooked into the
-context and so is used as the implementation. Pretty much how things work now
-except we'd have a redundant ENGINE pointer set to NULL and doing nothing.
-
-Conversely, if an ENGINE *has* been registered to perform the algorithm/mode
-combination represented by the provided EVP_CIPHER, then a functional reference
-to that ENGINE will be returned to the EVP_CIPHER_CTX during initialisation.
-That functional reference will be stored in the context (and released on
-cleanup) - and having that reference provides a *safe* way to use an EVP_CIPHER
-definition that is private to the ENGINE. Ie. the EVP_CIPHER provided by the
-application will actually be replaced by an EVP_CIPHER from the registered
-ENGINE - it will support the same algorithm/mode as the original but will be a
-completely different implementation. Because this EVP_CIPHER isn't stored in the
-EVP storage, nor is it returned to applications from traditional API functions,
-there is no associated problem with it not having reference counts. And of
-course, when one of these "private" cipher implementations is hooked into
-EVP_CIPHER_CTX, it is done whilst the EVP_CIPHER_CTX holds a functional
-reference to the ENGINE that owns it, thus the use of the ENGINE's EVP_CIPHER is
-safe.
-
-The "cipher-specific ENGINE code" I mentioned is implemented in tb_cipher.c but
-in essence it is simply an instantiation of "ENGINE_TABLE" code for use by
-EVP_CIPHER code. tb_digest.c is virtually identical but, of course, it is for
-use by EVP_MD code. Ditto for tb_rsa.c, tb_dsa.c, etc. These instantiations of
-ENGINE_TABLE essentially provide linker-separation of the classes so that even
-if ENGINEs implement *all* possible algorithms, an application using only
-EVP_CIPHER code will link at most code relating to EVP_CIPHER, tb_cipher.c, core
-ENGINE code that is independent of class, and of course the ENGINE
-implementation that the application loaded. It will *not* however link any
-class-specific ENGINE code for digests, RSA, etc nor will it bleed over into
-other APIs, such as the RSA/DSA/etc library code.
-
-ENGINE_TABLE is a little more complicated than may seem necessary but this is
-mostly to avoid a lot of "init()"-thrashing on ENGINEs (that may have to load
-DSOs, and other expensive setup that shouldn't be thrashed unnecessarily) *and*
-to duplicate "default" behaviour. Basically an ENGINE_TABLE instantiation, for
-example tb_cipher.c, implements a hash-table keyed by integer "nid" values.
-These nids provide the uniquenness of an algorithm/mode - and each nid will hash
-to a potentially NULL "ENGINE_PILE". An ENGINE_PILE is essentially a list of
-pointers to ENGINEs that implement that particular 'nid'. Each "pile" uses some
-caching tricks such that requests on that 'nid' will be cached and all future
-requests will return immediately (well, at least with minimal operation) unless
-a change is made to the pile, eg. perhaps an ENGINE was unloaded. The reason is
-that an application could have support for 10 ENGINEs statically linked
-in, and the machine in question may not have any of the hardware those 10
-ENGINEs support. If each of those ENGINEs has a "des_cbc" implementation, we
-want to avoid every EVP_CIPHER_CTX setup from trying (and failing) to initialise
-each of those 10 ENGINEs. Instead, the first such request will try to do that
-and will either return (and cache) a NULL ENGINE pointer or will return a
-functional reference to the first that successfully initialised. In the latter
-case it will also cache an extra functional reference to the ENGINE as a
-"default" for that 'nid'. The caching is acknowledged by a 'uptodate' variable
-that is unset only if un/registration takes place on that pile. Ie. if
-implementations of "des_cbc" are added or removed. This behaviour can be
-tweaked; the ENGINE_TABLE_FLAG_NOINIT value can be passed to
-ENGINE_set_table_flags(), in which case the only ENGINEs that tb_cipher.c will
-try to initialise from the "pile" will be those that are already initialised
-(ie. it's simply an increment of the functional reference count, and no real
-"initialisation" will take place).
-
-RSA, DSA, DH, and RAND all have their own ENGINE_TABLE code as well, and the
-difference is that they all use an implicit 'nid' of 1. Whereas EVP_CIPHERs are
-actually qualitatively different depending on 'nid' (the "des_cbc" EVP_CIPHER is
-not an interoperable implementation of "aes_256_cbc"), RSA_METHODs are
-necessarily interoperable and don't have different flavours, only different
-implementations. In other words, the ENGINE_TABLE for RSA will either be empty,
-or will have a single ENGINE_PILE hashed to by the 'nid' 1 and that pile
-represents ENGINEs that implement the single "type" of RSA there is.
-
-Cleanup - the registration and unregistration may pose questions about how
-cleanup works with the ENGINE_PILE doing all this caching nonsense (ie. when the
-application or EVP_CIPHER code releases its last reference to an ENGINE, the
-ENGINE_PILE code may still have references and thus those ENGINEs will stay
-hooked in forever). The way this is handled is via "unregistration". With these
-new ENGINE changes, an abstract ENGINE can be loaded and initialised, but that
-is an algorithm-agnostic process. Even if initialised, it will not have
-registered any of its implementations (to do so would link all class "table"
-code despite the fact the application may use only ciphers, for example). This
-is deliberately a distinct step. Moreover, registration and unregistration has
-nothing to do with whether an ENGINE is *functional* or not (ie. you can even
-register an ENGINE and its implementations without it being operational, you may
-not even have the drivers to make it operate). What actually happens with
-respect to cleanup is managed inside eng_lib.c with the "engine_cleanup_***"
-functions. These functions are internal-only and each part of ENGINE code that
-could require cleanup will, upon performing its first allocation, register a
-callback with the "engine_cleanup" code. The other part of this that makes it
-tick is that the ENGINE_TABLE instantiations (tb_***.c) use NULL as their
-initialised state. So if RSA code asks for an ENGINE and no ENGINE has
-registered an implementation, the code will simply return NULL and the tb_rsa.c
-state will be unchanged. Thus, no cleanup is required unless registration takes
-place. ENGINE_cleanup() will simply iterate across a list of registered cleanup
-callbacks calling each in turn, and will then internally delete its own storage
-(a STACK). When a cleanup callback is next registered (eg. if the cleanup() is
-part of a graceful restart and the application wants to cleanup all state then
-start again), the internal STACK storage will be freshly allocated. This is much
-the same as the situation in the ENGINE_TABLE instantiations ... NULL is the
-initialised state, so only modification operations (not queries) will cause that
-code to have to register a cleanup.
-
-What else? The bignum callbacks and associated ENGINE functions have been
-removed for two obvious reasons; (i) there was no way to generalise them to the
-mechanism now used by RSA/DSA/..., because there's no such thing as a BIGNUM
-method, and (ii) because of (i), there was no meaningful way for library or
-application code to automatically hook and use ENGINE supplied bignum functions
-anyway. Also, ENGINE_cpy() has been removed (although an internal-only version
-exists) - the idea of providing an ENGINE_cpy() function probably wasn't a good
-one and now certainly doesn't make sense in any generalised way. Some of the
-RSA, DSA, DH, and RAND functions that were fiddled during the original ENGINE
-changes have now, as a consequence, been reverted back. This is because the
-hooking of ENGINE is now automatic (and passive, it can internally use a NULL
-ENGINE pointer to simply ignore ENGINE from then on).
-
-Hell, that should be enough for now ... comments welcome.
-
+Notes: 2001-09-24
+-----------------
+
+This "description" (if one chooses to call it that) needed some major updating
+so here goes. This update addresses a change being made at the same time to
+OpenSSL, and it pretty much completely restructures the underlying mechanics of
+the "ENGINE" code. So it serves a double purpose of being a "ENGINE internals
+for masochists" document *and* a rather extensive commit log message. (I'd get
+lynched for sticking all this in CHANGES or the commit mails :-).
+
+ENGINE_TABLE underlies this restructuring, as described in the internal header
+"eng_local.h", implemented in eng_table.c, and used in each of the "class" files;
+tb_rsa.c, tb_dsa.c, etc.
+
+However, "EVP_CIPHER" underlies the motivation and design of ENGINE_TABLE so
+I'll mention a bit about that first. EVP_CIPHER (and most of this applies
+equally to EVP_MD for digests) is both a "method" and a algorithm/mode
+identifier that, in the current API, "lingers". These cipher description +
+implementation structures can be defined or obtained directly by applications,
+or can be loaded "en masse" into EVP storage so that they can be catalogued and
+searched in various ways, ie. two ways of encrypting with the "des_cbc"
+algorithm/mode pair are;
+
+(i) directly;
+ const EVP_CIPHER *cipher = EVP_des_cbc();
+ EVP_EncryptInit(&ctx, cipher, key, iv);
+ [ ... use EVP_EncryptUpdate() and EVP_EncryptFinal() ...]
+
+(ii) indirectly;
+ OpenSSL_add_all_ciphers();
+ cipher = EVP_get_cipherbyname("des_cbc");
+ EVP_EncryptInit(&ctx, cipher, key, iv);
+ [ ... etc ... ]
+
+The latter is more generally used because it also allows ciphers/digests to be
+looked up based on other identifiers which can be useful for automatic cipher
+selection, eg. in SSL/TLS, or by user-controllable configuration.
+
+The important point about this is that EVP_CIPHER definitions and structures are
+passed around with impunity and there is no safe way, without requiring massive
+rewrites of many applications, to assume that EVP_CIPHERs can be reference
+counted. One an EVP_CIPHER is exposed to the caller, neither it nor anything it
+comes from can "safely" be destroyed. Unless of course the way of getting to
+such ciphers is via entirely distinct API calls that didn't exist before.
+However existing API usage cannot be made to understand when an EVP_CIPHER
+pointer, that has been passed to the caller, is no longer being used.
+
+The other problem with the existing API w.r.t. to hooking EVP_CIPHER support
+into ENGINE is storage - the OBJ_NAME-based storage used by EVP to register
+ciphers simultaneously registers cipher *types* and cipher *implementations* -
+they are effectively the same thing, an "EVP_CIPHER" pointer. The problem with
+hooking in ENGINEs is that multiple ENGINEs may implement the same ciphers. The
+solution is necessarily that ENGINE-provided ciphers simply are not registered,
+stored, or exposed to the caller in the same manner as existing ciphers. This is
+especially necessary considering the fact ENGINE uses reference counts to allow
+for cleanup, modularity, and DSO support - yet EVP_CIPHERs, as exposed to
+callers in the current API, support no such controls.
+
+Another sticking point for integrating cipher support into ENGINE is linkage.
+Already there is a problem with the way ENGINE supports RSA, DSA, etc whereby
+they are available *because* they're part of a giant ENGINE called "openssl".
+Ie. all implementations *have* to come from an ENGINE, but we get round that by
+having a giant ENGINE with all the software support encapsulated. This creates
+linker hassles if nothing else - linking a 1-line application that calls 2 basic
+RSA functions (eg. "RSA_free(RSA_new());") will result in large quantities of
+ENGINE code being linked in *and* because of that DSA, DH, and RAND also. If we
+continue with this approach for EVP_CIPHER support (even if it *was* possible)
+we would lose our ability to link selectively by selectively loading certain
+implementations of certain functionality. Touching any part of any kind of
+crypto would result in massive static linkage of everything else. So the
+solution is to change the way ENGINE feeds existing "classes", ie. how the
+hooking to ENGINE works from RSA, DSA, DH, RAND, as well as adding new hooking
+for EVP_CIPHER, and EVP_MD.
+
+The way this is now being done is by mostly reverting back to how things used to
+work prior to ENGINE :-). Ie. RSA now has a "RSA_METHOD" pointer again - this
+was previously replaced by an "ENGINE" pointer and all RSA code that required
+the RSA_METHOD would call ENGINE_get_RSA() each time on its ENGINE handle to
+temporarily get and use the ENGINE's RSA implementation. Apart from being more
+efficient, switching back to each RSA having an RSA_METHOD pointer also allows
+us to conceivably operate with *no* ENGINE. As we'll see, this removes any need
+for a fallback ENGINE that encapsulates default implementations - we can simply
+have our RSA structure pointing its RSA_METHOD pointer to the software
+implementation and have its ENGINE pointer set to NULL.
+
+A look at the EVP_CIPHER hooking is most explanatory, the RSA, DSA (etc) cases
+turn out to be degenerate forms of the same thing. The EVP storage of ciphers,
+and the existing EVP API functions that return "software" implementations and
+descriptions remain untouched. However, the storage takes more meaning in terms
+of "cipher description" and less meaning in terms of "implementation". When an
+EVP_CIPHER_CTX is actually initialised with an EVP_CIPHER method and is about to
+begin en/decryption, the hooking to ENGINE comes into play. What happens is that
+cipher-specific ENGINE code is asked for an ENGINE pointer (a functional
+reference) for any ENGINE that is registered to perform the algo/mode that the
+provided EVP_CIPHER structure represents. Under normal circumstances, that
+ENGINE code will return NULL because no ENGINEs will have had any cipher
+implementations *registered*. As such, a NULL ENGINE pointer is stored in the
+EVP_CIPHER_CTX context, and the EVP_CIPHER structure is left hooked into the
+context and so is used as the implementation. Pretty much how things work now
+except we'd have a redundant ENGINE pointer set to NULL and doing nothing.
+
+Conversely, if an ENGINE *has* been registered to perform the algorithm/mode
+combination represented by the provided EVP_CIPHER, then a functional reference
+to that ENGINE will be returned to the EVP_CIPHER_CTX during initialisation.
+That functional reference will be stored in the context (and released on
+cleanup) - and having that reference provides a *safe* way to use an EVP_CIPHER
+definition that is private to the ENGINE. Ie. the EVP_CIPHER provided by the
+application will actually be replaced by an EVP_CIPHER from the registered
+ENGINE - it will support the same algorithm/mode as the original but will be a
+completely different implementation. Because this EVP_CIPHER isn't stored in the
+EVP storage, nor is it returned to applications from traditional API functions,
+there is no associated problem with it not having reference counts. And of
+course, when one of these "private" cipher implementations is hooked into
+EVP_CIPHER_CTX, it is done whilst the EVP_CIPHER_CTX holds a functional
+reference to the ENGINE that owns it, thus the use of the ENGINE's EVP_CIPHER is
+safe.
+
+The "cipher-specific ENGINE code" I mentioned is implemented in tb_cipher.c but
+in essence it is simply an instantiation of "ENGINE_TABLE" code for use by
+EVP_CIPHER code. tb_digest.c is virtually identical but, of course, it is for
+use by EVP_MD code. Ditto for tb_rsa.c, tb_dsa.c, etc. These instantiations of
+ENGINE_TABLE essentially provide linker-separation of the classes so that even
+if ENGINEs implement *all* possible algorithms, an application using only
+EVP_CIPHER code will link at most code relating to EVP_CIPHER, tb_cipher.c, core
+ENGINE code that is independent of class, and of course the ENGINE
+implementation that the application loaded. It will *not* however link any
+class-specific ENGINE code for digests, RSA, etc nor will it bleed over into
+other APIs, such as the RSA/DSA/etc library code.
+
+ENGINE_TABLE is a little more complicated than may seem necessary but this is
+mostly to avoid a lot of "init()"-thrashing on ENGINEs (that may have to load
+DSOs, and other expensive setup that shouldn't be thrashed unnecessarily) *and*
+to duplicate "default" behaviour. Basically an ENGINE_TABLE instantiation, for
+example tb_cipher.c, implements a hash-table keyed by integer "nid" values.
+These nids provide the uniquenness of an algorithm/mode - and each nid will hash
+to a potentially NULL "ENGINE_PILE". An ENGINE_PILE is essentially a list of
+pointers to ENGINEs that implement that particular 'nid'. Each "pile" uses some
+caching tricks such that requests on that 'nid' will be cached and all future
+requests will return immediately (well, at least with minimal operation) unless
+a change is made to the pile, eg. perhaps an ENGINE was unloaded. The reason is
+that an application could have support for 10 ENGINEs statically linked
+in, and the machine in question may not have any of the hardware those 10
+ENGINEs support. If each of those ENGINEs has a "des_cbc" implementation, we
+want to avoid every EVP_CIPHER_CTX setup from trying (and failing) to initialise
+each of those 10 ENGINEs. Instead, the first such request will try to do that
+and will either return (and cache) a NULL ENGINE pointer or will return a
+functional reference to the first that successfully initialised. In the latter
+case it will also cache an extra functional reference to the ENGINE as a
+"default" for that 'nid'. The caching is acknowledged by a 'uptodate' variable
+that is unset only if un/registration takes place on that pile. Ie. if
+implementations of "des_cbc" are added or removed. This behaviour can be
+tweaked; the ENGINE_TABLE_FLAG_NOINIT value can be passed to
+ENGINE_set_table_flags(), in which case the only ENGINEs that tb_cipher.c will
+try to initialise from the "pile" will be those that are already initialised
+(ie. it's simply an increment of the functional reference count, and no real
+"initialisation" will take place).
+
+RSA, DSA, DH, and RAND all have their own ENGINE_TABLE code as well, and the
+difference is that they all use an implicit 'nid' of 1. Whereas EVP_CIPHERs are
+actually qualitatively different depending on 'nid' (the "des_cbc" EVP_CIPHER is
+not an interoperable implementation of "aes_256_cbc"), RSA_METHODs are
+necessarily interoperable and don't have different flavours, only different
+implementations. In other words, the ENGINE_TABLE for RSA will either be empty,
+or will have a single ENGINE_PILE hashed to by the 'nid' 1 and that pile
+represents ENGINEs that implement the single "type" of RSA there is.
+
+Cleanup - the registration and unregistration may pose questions about how
+cleanup works with the ENGINE_PILE doing all this caching nonsense (ie. when the
+application or EVP_CIPHER code releases its last reference to an ENGINE, the
+ENGINE_PILE code may still have references and thus those ENGINEs will stay
+hooked in forever). The way this is handled is via "unregistration". With these
+new ENGINE changes, an abstract ENGINE can be loaded and initialised, but that
+is an algorithm-agnostic process. Even if initialised, it will not have
+registered any of its implementations (to do so would link all class "table"
+code despite the fact the application may use only ciphers, for example). This
+is deliberately a distinct step. Moreover, registration and unregistration has
+nothing to do with whether an ENGINE is *functional* or not (ie. you can even
+register an ENGINE and its implementations without it being operational, you may
+not even have the drivers to make it operate). What actually happens with
+respect to cleanup is managed inside eng_lib.c with the "engine_cleanup_***"
+functions. These functions are internal-only and each part of ENGINE code that
+could require cleanup will, upon performing its first allocation, register a
+callback with the "engine_cleanup" code. The other part of this that makes it
+tick is that the ENGINE_TABLE instantiations (tb_***.c) use NULL as their
+initialised state. So if RSA code asks for an ENGINE and no ENGINE has
+registered an implementation, the code will simply return NULL and the tb_rsa.c
+state will be unchanged. Thus, no cleanup is required unless registration takes
+place. ENGINE_cleanup() will simply iterate across a list of registered cleanup
+callbacks calling each in turn, and will then internally delete its own storage
+(a STACK). When a cleanup callback is next registered (eg. if the cleanup() is
+part of a graceful restart and the application wants to cleanup all state then
+start again), the internal STACK storage will be freshly allocated. This is much
+the same as the situation in the ENGINE_TABLE instantiations ... NULL is the
+initialised state, so only modification operations (not queries) will cause that
+code to have to register a cleanup.
+
+What else? The bignum callbacks and associated ENGINE functions have been
+removed for two obvious reasons; (i) there was no way to generalise them to the
+mechanism now used by RSA/DSA/..., because there's no such thing as a BIGNUM
+method, and (ii) because of (i), there was no meaningful way for library or
+application code to automatically hook and use ENGINE supplied bignum functions
+anyway. Also, ENGINE_cpy() has been removed (although an internal-only version
+exists) - the idea of providing an ENGINE_cpy() function probably wasn't a good
+one and now certainly doesn't make sense in any generalised way. Some of the
+RSA, DSA, DH, and RAND functions that were fiddled during the original ENGINE
+changes have now, as a consequence, been reverted back. This is because the
+hooking of ENGINE is now automatic (and passive, it can internally use a NULL
+ENGINE pointer to simply ignore ENGINE from then on).
+
+Hell, that should be enough for now ... comments welcome.
+
diff --git a/contrib/libs/openssl/crypto/engine/eng_devcrypto.c b/contrib/libs/openssl/crypto/engine/eng_devcrypto.c
index c6b871f464..84a3b7dbec 100644
--- a/contrib/libs/openssl/crypto/engine/eng_devcrypto.c
+++ b/contrib/libs/openssl/crypto/engine/eng_devcrypto.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2017-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2017-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -758,9 +758,9 @@ static int devcrypto_unload(ENGINE *e)
void engine_load_devcrypto_int()
{
ENGINE *e = NULL;
- int fd;
+ int fd;
- if ((fd = open("/dev/crypto", O_RDWR, 0)) < 0) {
+ if ((fd = open("/dev/crypto", O_RDWR, 0)) < 0) {
#ifndef ENGINE_DEVCRYPTO_DEBUG
if (errno != ENOENT)
#endif
@@ -768,18 +768,18 @@ void engine_load_devcrypto_int()
return;
}
-#ifdef CRIOGET
- if (ioctl(fd, CRIOGET, &cfd) < 0) {
- fprintf(stderr, "Could not create crypto fd: %s\n", strerror(errno));
- close(fd);
- cfd = -1;
- return;
- }
- close(fd);
-#else
- cfd = fd;
-#endif
-
+#ifdef CRIOGET
+ if (ioctl(fd, CRIOGET, &cfd) < 0) {
+ fprintf(stderr, "Could not create crypto fd: %s\n", strerror(errno));
+ close(fd);
+ cfd = -1;
+ return;
+ }
+ close(fd);
+#else
+ cfd = fd;
+#endif
+
if ((e = ENGINE_new()) == NULL
|| !ENGINE_set_destroy_function(e, devcrypto_unload)) {
ENGINE_free(e);
diff --git a/contrib/libs/openssl/crypto/engine/eng_lib.c b/contrib/libs/openssl/crypto/engine/eng_lib.c
index 500e4d65cd..5bd584c599 100644
--- a/contrib/libs/openssl/crypto/engine/eng_lib.c
+++ b/contrib/libs/openssl/crypto/engine/eng_lib.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2001-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2001-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -171,7 +171,7 @@ void engine_cleanup_int(void)
cleanup_stack = NULL;
}
CRYPTO_THREAD_lock_free(global_engine_lock);
- global_engine_lock = NULL;
+ global_engine_lock = NULL;
}
/* Now the "ex_data" support */
diff --git a/contrib/libs/openssl/crypto/err/README b/contrib/libs/openssl/crypto/err/README
index 4ad3f1aa66..6d2ce0cd0e 100644
--- a/contrib/libs/openssl/crypto/err/README
+++ b/contrib/libs/openssl/crypto/err/README
@@ -1,44 +1,44 @@
-Adding new libraries
---------------------
-
-When adding a new sub-library to OpenSSL, assign it a library number
-ERR_LIB_XXX, define a macro XXXerr() (both in err.h), add its
-name to ERR_str_libraries[] (in crypto/err/err.c), and add
-ERR_load_XXX_strings() to the ERR_load_crypto_strings() function
-(in crypto/err/err_all.c). Finally, add an entry:
-
- L XXX xxx.h xxx_err.c
-
-to crypto/err/openssl.ec, and add xxx_err.c to the Makefile.
-Running make errors will then generate a file xxx_err.c, and
-add all error codes used in the library to xxx.h.
-
-Additionally the library include file must have a certain form.
-Typically it will initially look like this:
-
- #ifndef HEADER_XXX_H
- #define HEADER_XXX_H
-
- #ifdef __cplusplus
- extern "C" {
- #endif
-
- /* Include files */
-
- #include <openssl/bio.h>
- #include <openssl/x509.h>
-
- /* Macros, structures and function prototypes */
-
-
- /* BEGIN ERROR CODES */
-
-The BEGIN ERROR CODES sequence is used by the error code
-generation script as the point to place new error codes, any text
-after this point will be overwritten when make errors is run.
-The closing #endif etc will be automatically added by the script.
-
-The generated C error code file xxx_err.c will load the header
-files stdio.h, openssl/err.h and openssl/xxx.h so the
-header file must load any additional header files containing any
-definitions it uses.
+Adding new libraries
+--------------------
+
+When adding a new sub-library to OpenSSL, assign it a library number
+ERR_LIB_XXX, define a macro XXXerr() (both in err.h), add its
+name to ERR_str_libraries[] (in crypto/err/err.c), and add
+ERR_load_XXX_strings() to the ERR_load_crypto_strings() function
+(in crypto/err/err_all.c). Finally, add an entry:
+
+ L XXX xxx.h xxx_err.c
+
+to crypto/err/openssl.ec, and add xxx_err.c to the Makefile.
+Running make errors will then generate a file xxx_err.c, and
+add all error codes used in the library to xxx.h.
+
+Additionally the library include file must have a certain form.
+Typically it will initially look like this:
+
+ #ifndef HEADER_XXX_H
+ #define HEADER_XXX_H
+
+ #ifdef __cplusplus
+ extern "C" {
+ #endif
+
+ /* Include files */
+
+ #include <openssl/bio.h>
+ #include <openssl/x509.h>
+
+ /* Macros, structures and function prototypes */
+
+
+ /* BEGIN ERROR CODES */
+
+The BEGIN ERROR CODES sequence is used by the error code
+generation script as the point to place new error codes, any text
+after this point will be overwritten when make errors is run.
+The closing #endif etc will be automatically added by the script.
+
+The generated C error code file xxx_err.c will load the header
+files stdio.h, openssl/err.h and openssl/xxx.h so the
+header file must load any additional header files containing any
+definitions it uses.
diff --git a/contrib/libs/openssl/crypto/evp/bio_ok.c b/contrib/libs/openssl/crypto/evp/bio_ok.c
index 77886f1698..9610f3c1ef 100644
--- a/contrib/libs/openssl/crypto/evp/bio_ok.c
+++ b/contrib/libs/openssl/crypto/evp/bio_ok.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -203,7 +203,7 @@ static int ok_read(BIO *b, char *out, int outl)
/*
* copy start of the next block into proper place
*/
- if (ctx->buf_len_save > ctx->buf_off_save) {
+ if (ctx->buf_len_save > ctx->buf_off_save) {
ctx->buf_len = ctx->buf_len_save - ctx->buf_off_save;
memmove(ctx->buf, &(ctx->buf[ctx->buf_off_save]),
ctx->buf_len);
diff --git a/contrib/libs/openssl/crypto/evp/e_aes.c b/contrib/libs/openssl/crypto/evp/e_aes.c
index 65f9b74696..2c2812fdf1 100644
--- a/contrib/libs/openssl/crypto/evp/e_aes.c
+++ b/contrib/libs/openssl/crypto/evp/e_aes.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2001-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2001-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -614,22 +614,22 @@ void aes_t4_decrypt(const unsigned char *in, unsigned char *out,
*/
void aes128_t4_cbc_encrypt(const unsigned char *in, unsigned char *out,
size_t len, const AES_KEY *key,
- unsigned char *ivec, int /*unused*/);
+ unsigned char *ivec, int /*unused*/);
void aes128_t4_cbc_decrypt(const unsigned char *in, unsigned char *out,
size_t len, const AES_KEY *key,
- unsigned char *ivec, int /*unused*/);
+ unsigned char *ivec, int /*unused*/);
void aes192_t4_cbc_encrypt(const unsigned char *in, unsigned char *out,
size_t len, const AES_KEY *key,
- unsigned char *ivec, int /*unused*/);
+ unsigned char *ivec, int /*unused*/);
void aes192_t4_cbc_decrypt(const unsigned char *in, unsigned char *out,
size_t len, const AES_KEY *key,
- unsigned char *ivec, int /*unused*/);
+ unsigned char *ivec, int /*unused*/);
void aes256_t4_cbc_encrypt(const unsigned char *in, unsigned char *out,
size_t len, const AES_KEY *key,
- unsigned char *ivec, int /*unused*/);
+ unsigned char *ivec, int /*unused*/);
void aes256_t4_cbc_decrypt(const unsigned char *in, unsigned char *out,
size_t len, const AES_KEY *key,
- unsigned char *ivec, int /*unused*/);
+ unsigned char *ivec, int /*unused*/);
void aes128_t4_ctr32_encrypt(const unsigned char *in, unsigned char *out,
size_t blocks, const AES_KEY *key,
unsigned char *ivec);
@@ -1171,9 +1171,9 @@ typedef struct {
static int s390x_aes_init_key(EVP_CIPHER_CTX *ctx, const unsigned char *key,
const unsigned char *iv, int enc);
-# define S390X_aes_128_cbc_CAPABLE 0 /* checked by callee */
-# define S390X_aes_192_cbc_CAPABLE 0
-# define S390X_aes_256_cbc_CAPABLE 0
+# define S390X_aes_128_cbc_CAPABLE 0 /* checked by callee */
+# define S390X_aes_192_cbc_CAPABLE 0
+# define S390X_aes_256_cbc_CAPABLE 0
# define S390X_AES_CBC_CTX EVP_AES_KEY
# define s390x_aes_cbc_init_key aes_init_key
@@ -1193,11 +1193,11 @@ static int s390x_aes_ecb_init_key(EVP_CIPHER_CTX *ctx,
S390X_AES_ECB_CTX *cctx = EVP_C_DATA(S390X_AES_ECB_CTX, ctx);
const int keylen = EVP_CIPHER_CTX_key_length(ctx);
- cctx->fc = S390X_AES_FC(keylen) | (enc ? 0 : S390X_DECRYPT);
+ cctx->fc = S390X_AES_FC(keylen) | (enc ? 0 : S390X_DECRYPT);
+
+ if (key != NULL)
+ memcpy(cctx->km.param.k, key, keylen);
- if (key != NULL)
- memcpy(cctx->km.param.k, key, keylen);
-
return 1;
}
@@ -1225,17 +1225,17 @@ static int s390x_aes_ofb_init_key(EVP_CIPHER_CTX *ctx,
const unsigned char *ivec, int enc)
{
S390X_AES_OFB_CTX *cctx = EVP_C_DATA(S390X_AES_OFB_CTX, ctx);
- const unsigned char *oiv = EVP_CIPHER_CTX_original_iv(ctx);
+ const unsigned char *oiv = EVP_CIPHER_CTX_original_iv(ctx);
const int keylen = EVP_CIPHER_CTX_key_length(ctx);
const int ivlen = EVP_CIPHER_CTX_iv_length(ctx);
cctx->fc = S390X_AES_FC(keylen);
-
- if (key != NULL)
- memcpy(cctx->kmo.param.k, key, keylen);
-
+
+ if (key != NULL)
+ memcpy(cctx->kmo.param.k, key, keylen);
+
cctx->res = 0;
- memcpy(cctx->kmo.param.cv, oiv, ivlen);
+ memcpy(cctx->kmo.param.cv, oiv, ivlen);
return 1;
}
@@ -1243,12 +1243,12 @@ static int s390x_aes_ofb_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out,
const unsigned char *in, size_t len)
{
S390X_AES_OFB_CTX *cctx = EVP_C_DATA(S390X_AES_OFB_CTX, ctx);
- const int ivlen = EVP_CIPHER_CTX_iv_length(ctx);
- unsigned char *iv = EVP_CIPHER_CTX_iv_noconst(ctx);
+ const int ivlen = EVP_CIPHER_CTX_iv_length(ctx);
+ unsigned char *iv = EVP_CIPHER_CTX_iv_noconst(ctx);
int n = cctx->res;
int rem;
- memcpy(cctx->kmo.param.cv, iv, ivlen);
+ memcpy(cctx->kmo.param.cv, iv, ivlen);
while (n && len) {
*out = *in ^ cctx->kmo.param.cv[n];
n = (n + 1) & 0xf;
@@ -1277,7 +1277,7 @@ static int s390x_aes_ofb_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out,
}
}
- memcpy(iv, cctx->kmo.param.cv, ivlen);
+ memcpy(iv, cctx->kmo.param.cv, ivlen);
cctx->res = n;
return 1;
}
@@ -1297,18 +1297,18 @@ static int s390x_aes_cfb_init_key(EVP_CIPHER_CTX *ctx,
const unsigned char *ivec, int enc)
{
S390X_AES_CFB_CTX *cctx = EVP_C_DATA(S390X_AES_CFB_CTX, ctx);
- const unsigned char *oiv = EVP_CIPHER_CTX_original_iv(ctx);
+ const unsigned char *oiv = EVP_CIPHER_CTX_original_iv(ctx);
const int keylen = EVP_CIPHER_CTX_key_length(ctx);
const int ivlen = EVP_CIPHER_CTX_iv_length(ctx);
- cctx->fc = S390X_AES_FC(keylen) | (enc ? 0 : S390X_DECRYPT)
- | (16 << 24); /* 16 bytes cipher feedback */
+ cctx->fc = S390X_AES_FC(keylen) | (enc ? 0 : S390X_DECRYPT)
+ | (16 << 24); /* 16 bytes cipher feedback */
+
+ if (key != NULL)
+ memcpy(cctx->kmf.param.k, key, keylen);
- if (key != NULL)
- memcpy(cctx->kmf.param.k, key, keylen);
-
cctx->res = 0;
- memcpy(cctx->kmf.param.cv, oiv, ivlen);
+ memcpy(cctx->kmf.param.cv, oiv, ivlen);
return 1;
}
@@ -1318,13 +1318,13 @@ static int s390x_aes_cfb_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out,
S390X_AES_CFB_CTX *cctx = EVP_C_DATA(S390X_AES_CFB_CTX, ctx);
const int keylen = EVP_CIPHER_CTX_key_length(ctx);
const int enc = EVP_CIPHER_CTX_encrypting(ctx);
- const int ivlen = EVP_CIPHER_CTX_iv_length(ctx);
- unsigned char *iv = EVP_CIPHER_CTX_iv_noconst(ctx);
+ const int ivlen = EVP_CIPHER_CTX_iv_length(ctx);
+ unsigned char *iv = EVP_CIPHER_CTX_iv_noconst(ctx);
int n = cctx->res;
int rem;
unsigned char tmp;
- memcpy(cctx->kmf.param.cv, iv, ivlen);
+ memcpy(cctx->kmf.param.cv, iv, ivlen);
while (n && len) {
tmp = *in;
*out = cctx->kmf.param.cv[n] ^ tmp;
@@ -1357,7 +1357,7 @@ static int s390x_aes_cfb_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out,
}
}
- memcpy(iv, cctx->kmf.param.cv, ivlen);
+ memcpy(iv, cctx->kmf.param.cv, ivlen);
cctx->res = n;
return 1;
}
@@ -1374,18 +1374,18 @@ static int s390x_aes_cfb8_init_key(EVP_CIPHER_CTX *ctx,
const unsigned char *ivec, int enc)
{
S390X_AES_CFB_CTX *cctx = EVP_C_DATA(S390X_AES_CFB_CTX, ctx);
- const unsigned char *oiv = EVP_CIPHER_CTX_original_iv(ctx);
+ const unsigned char *oiv = EVP_CIPHER_CTX_original_iv(ctx);
const int keylen = EVP_CIPHER_CTX_key_length(ctx);
const int ivlen = EVP_CIPHER_CTX_iv_length(ctx);
- cctx->fc = S390X_AES_FC(keylen) | (enc ? 0 : S390X_DECRYPT)
- | (1 << 24); /* 1 byte cipher feedback flag */
+ cctx->fc = S390X_AES_FC(keylen) | (enc ? 0 : S390X_DECRYPT)
+ | (1 << 24); /* 1 byte cipher feedback flag */
+
+ if (key != NULL)
+ memcpy(cctx->kmf.param.k, key, keylen);
- if (key != NULL)
- memcpy(cctx->kmf.param.k, key, keylen);
-
- cctx->res = 0;
- memcpy(cctx->kmf.param.cv, oiv, ivlen);
+ cctx->res = 0;
+ memcpy(cctx->kmf.param.cv, oiv, ivlen);
return 1;
}
@@ -1393,12 +1393,12 @@ static int s390x_aes_cfb8_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out,
const unsigned char *in, size_t len)
{
S390X_AES_CFB_CTX *cctx = EVP_C_DATA(S390X_AES_CFB_CTX, ctx);
- const int ivlen = EVP_CIPHER_CTX_iv_length(ctx);
- unsigned char *iv = EVP_CIPHER_CTX_iv_noconst(ctx);
+ const int ivlen = EVP_CIPHER_CTX_iv_length(ctx);
+ unsigned char *iv = EVP_CIPHER_CTX_iv_noconst(ctx);
- memcpy(cctx->kmf.param.cv, iv, ivlen);
+ memcpy(cctx->kmf.param.cv, iv, ivlen);
s390x_kmf(in, len, out, cctx->fc, &cctx->kmf.param);
- memcpy(iv, cctx->kmf.param.cv, ivlen);
+ memcpy(iv, cctx->kmf.param.cv, ivlen);
return 1;
}
@@ -1412,9 +1412,9 @@ static int s390x_aes_cfb8_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out,
static int s390x_aes_cfb1_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out,
const unsigned char *in, size_t len);
-# define S390X_aes_128_ctr_CAPABLE 0 /* checked by callee */
-# define S390X_aes_192_ctr_CAPABLE 0
-# define S390X_aes_256_ctr_CAPABLE 0
+# define S390X_aes_128_ctr_CAPABLE 0 /* checked by callee */
+# define S390X_aes_192_ctr_CAPABLE 0
+# define S390X_aes_256_ctr_CAPABLE 0
# define S390X_AES_CTR_CTX EVP_AES_KEY
# define s390x_aes_ctr_init_key aes_init_key
@@ -1582,7 +1582,7 @@ static int s390x_aes_gcm(S390X_AES_GCM_CTX *ctx, const unsigned char *in,
/*-
* Initialize context structure. Code is big-endian.
*/
-static void s390x_aes_gcm_setiv(S390X_AES_GCM_CTX *ctx)
+static void s390x_aes_gcm_setiv(S390X_AES_GCM_CTX *ctx)
{
ctx->kma.param.t.g[0] = 0;
ctx->kma.param.t.g[1] = 0;
@@ -1593,7 +1593,7 @@ static void s390x_aes_gcm_setiv(S390X_AES_GCM_CTX *ctx)
ctx->kreslen = 0;
if (ctx->ivlen == 12) {
- memcpy(&ctx->kma.param.j0, ctx->iv, ctx->ivlen);
+ memcpy(&ctx->kma.param.j0, ctx->iv, ctx->ivlen);
ctx->kma.param.j0.w[3] = 1;
ctx->kma.param.cv.w = 1;
} else {
@@ -1711,7 +1711,7 @@ static int s390x_aes_gcm_ctrl(EVP_CIPHER_CTX *c, int type, int arg, void *ptr)
if (gctx->iv_gen == 0 || gctx->key_set == 0)
return 0;
- s390x_aes_gcm_setiv(gctx);
+ s390x_aes_gcm_setiv(gctx);
if (arg <= 0 || arg > gctx->ivlen)
arg = gctx->ivlen;
@@ -1731,7 +1731,7 @@ static int s390x_aes_gcm_ctrl(EVP_CIPHER_CTX *c, int type, int arg, void *ptr)
return 0;
memcpy(gctx->iv + gctx->ivlen - arg, ptr, arg);
- s390x_aes_gcm_setiv(gctx);
+ s390x_aes_gcm_setiv(gctx);
gctx->iv_set = 1;
return 1;
@@ -1787,36 +1787,36 @@ static int s390x_aes_gcm_ctrl(EVP_CIPHER_CTX *c, int type, int arg, void *ptr)
}
/*-
- * Set key or iv or enc/dec. Returns 1 on success. Otherwise 0 is returned.
+ * Set key or iv or enc/dec. Returns 1 on success. Otherwise 0 is returned.
*/
static int s390x_aes_gcm_init_key(EVP_CIPHER_CTX *ctx,
const unsigned char *key,
const unsigned char *iv, int enc)
{
S390X_AES_GCM_CTX *gctx = EVP_C_DATA(S390X_AES_GCM_CTX, ctx);
- const int keylen = EVP_CIPHER_CTX_key_length(ctx);
+ const int keylen = EVP_CIPHER_CTX_key_length(ctx);
- gctx->fc = S390X_AES_FC(keylen) | (enc ? 0 : S390X_DECRYPT);
+ gctx->fc = S390X_AES_FC(keylen) | (enc ? 0 : S390X_DECRYPT);
if (key != NULL) {
- gctx->fc &= ~S390X_KMA_HS;
+ gctx->fc &= ~S390X_KMA_HS;
memcpy(&gctx->kma.param.k, key, keylen);
gctx->key_set = 1;
- }
+ }
- if (iv != NULL) {
- memcpy(gctx->iv, iv, gctx->ivlen);
- gctx->iv_gen = 0;
+ if (iv != NULL) {
+ memcpy(gctx->iv, iv, gctx->ivlen);
+ gctx->iv_gen = 0;
gctx->iv_set = 1;
}
-
- if (gctx->key_set && gctx->iv_set)
- s390x_aes_gcm_setiv(gctx);
-
- gctx->fc &= ~(S390X_KMA_LPC | S390X_KMA_LAAD);
- gctx->areslen = 0;
- gctx->mreslen = 0;
- gctx->kreslen = 0;
+
+ if (gctx->key_set && gctx->iv_set)
+ s390x_aes_gcm_setiv(gctx);
+
+ gctx->fc &= ~(S390X_KMA_LPC | S390X_KMA_LAAD);
+ gctx->areslen = 0;
+ gctx->mreslen = 0;
+ gctx->kreslen = 0;
return 1;
}
@@ -1938,8 +1938,8 @@ static int s390x_aes_gcm_cleanup(EVP_CIPHER_CTX *c)
}
# define S390X_AES_XTS_CTX EVP_AES_XTS_CTX
-# define S390X_aes_128_xts_CAPABLE 0 /* checked by callee */
-# define S390X_aes_256_xts_CAPABLE 0
+# define S390X_aes_128_xts_CAPABLE 0 /* checked by callee */
+# define S390X_aes_256_xts_CAPABLE 0
# define s390x_aes_xts_init_key aes_xts_init_key
static int s390x_aes_xts_init_key(EVP_CIPHER_CTX *ctx,
@@ -2143,10 +2143,10 @@ static int s390x_aes_ccm_tls_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out,
const unsigned char *in, size_t len)
{
S390X_AES_CCM_CTX *cctx = EVP_C_DATA(S390X_AES_CCM_CTX, ctx);
- const unsigned char *ivec = EVP_CIPHER_CTX_iv(ctx);
+ const unsigned char *ivec = EVP_CIPHER_CTX_iv(ctx);
unsigned char *buf = EVP_CIPHER_CTX_buf_noconst(ctx);
const int enc = EVP_CIPHER_CTX_encrypting(ctx);
- unsigned char iv[EVP_MAX_IV_LENGTH];
+ unsigned char iv[EVP_MAX_IV_LENGTH];
if (out != in
|| len < (EVP_CCM_TLS_EXPLICIT_IV_LEN + (size_t)cctx->aes.ccm.m))
@@ -2162,9 +2162,9 @@ static int s390x_aes_ccm_tls_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out,
* Get explicit iv (sequence number). We already have fixed iv
* (server/client_write_iv) here.
*/
- memcpy(iv, ivec, sizeof(iv));
- memcpy(iv + EVP_CCM_TLS_FIXED_IV_LEN, in, EVP_CCM_TLS_EXPLICIT_IV_LEN);
- s390x_aes_ccm_setiv(cctx, iv, len);
+ memcpy(iv, ivec, sizeof(iv));
+ memcpy(iv + EVP_CCM_TLS_FIXED_IV_LEN, in, EVP_CCM_TLS_EXPLICIT_IV_LEN);
+ s390x_aes_ccm_setiv(cctx, iv, len);
/* Process aad (sequence number|type|version|length) */
s390x_aes_ccm_aad(cctx, buf, cctx->aes.ccm.tls_aad_len);
@@ -2191,18 +2191,18 @@ static int s390x_aes_ccm_tls_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out,
}
/*-
- * Set key or iv or enc/dec. Returns 1 if successful.
- * Otherwise 0 is returned.
+ * Set key or iv or enc/dec. Returns 1 if successful.
+ * Otherwise 0 is returned.
*/
static int s390x_aes_ccm_init_key(EVP_CIPHER_CTX *ctx,
const unsigned char *key,
const unsigned char *iv, int enc)
{
S390X_AES_CCM_CTX *cctx = EVP_C_DATA(S390X_AES_CCM_CTX, ctx);
- const int keylen = EVP_CIPHER_CTX_key_length(ctx);
- unsigned char *ivec = EVP_CIPHER_CTX_iv_noconst(ctx);
+ const int keylen = EVP_CIPHER_CTX_key_length(ctx);
+ unsigned char *ivec = EVP_CIPHER_CTX_iv_noconst(ctx);
- cctx->aes.ccm.fc = S390X_AES_FC(keylen);
+ cctx->aes.ccm.fc = S390X_AES_FC(keylen);
if (key != NULL) {
memcpy(cctx->aes.ccm.kmac_param.k, key, keylen);
@@ -2213,13 +2213,13 @@ static int s390x_aes_ccm_init_key(EVP_CIPHER_CTX *ctx,
cctx->aes.ccm.iv_set = 1;
}
- /* Store encoded m and l. */
- cctx->aes.ccm.nonce.b[0] = ((cctx->aes.ccm.l - 1) & 0x7)
- | (((cctx->aes.ccm.m - 2) >> 1) & 0x7) << 3;
- memset(cctx->aes.ccm.nonce.b + 1, 0, sizeof(cctx->aes.ccm.nonce.b) - 1);
-
- cctx->aes.ccm.blocks = 0;
- cctx->aes.ccm.len_set = 0;
+ /* Store encoded m and l. */
+ cctx->aes.ccm.nonce.b[0] = ((cctx->aes.ccm.l - 1) & 0x7)
+ | (((cctx->aes.ccm.m - 2) >> 1) & 0x7) << 3;
+ memset(cctx->aes.ccm.nonce.b + 1, 0, sizeof(cctx->aes.ccm.nonce.b) - 1);
+
+ cctx->aes.ccm.blocks = 0;
+ cctx->aes.ccm.len_set = 0;
return 1;
}
@@ -2234,8 +2234,8 @@ static int s390x_aes_ccm_cipher(EVP_CIPHER_CTX *ctx, unsigned char *out,
{
S390X_AES_CCM_CTX *cctx = EVP_C_DATA(S390X_AES_CCM_CTX, ctx);
const int enc = EVP_CIPHER_CTX_encrypting(ctx);
- const unsigned char *ivec = EVP_CIPHER_CTX_iv(ctx);
- unsigned char *buf;
+ const unsigned char *ivec = EVP_CIPHER_CTX_iv(ctx);
+ unsigned char *buf;
int rv;
if (!cctx->aes.ccm.key_set)
@@ -2450,7 +2450,7 @@ static const EVP_CIPHER s390x_aes_##keylen##_##mode = { \
nid##_##keylen##_##nmode,blocksize, \
keylen / 8, \
ivlen, \
- flags | EVP_CIPH_ALWAYS_CALL_INIT | EVP_CIPH_##MODE##_MODE, \
+ flags | EVP_CIPH_ALWAYS_CALL_INIT | EVP_CIPH_##MODE##_MODE, \
s390x_aes_##mode##_init_key, \
s390x_aes_##mode##_cipher, \
NULL, \
@@ -2487,7 +2487,7 @@ static const EVP_CIPHER s390x_aes_##keylen##_##mode = { \
blocksize, \
(EVP_CIPH_##MODE##_MODE == EVP_CIPH_XTS_MODE ? 2 : 1) * keylen / 8, \
ivlen, \
- flags | EVP_CIPH_ALWAYS_CALL_INIT | EVP_CIPH_##MODE##_MODE, \
+ flags | EVP_CIPH_ALWAYS_CALL_INIT | EVP_CIPH_##MODE##_MODE, \
s390x_aes_##mode##_init_key, \
s390x_aes_##mode##_cipher, \
s390x_aes_##mode##_cleanup, \
diff --git a/contrib/libs/openssl/crypto/evp/e_camellia.c b/contrib/libs/openssl/crypto/evp/e_camellia.c
index 7e03317bbd..f8c0198012 100644
--- a/contrib/libs/openssl/crypto/evp/e_camellia.c
+++ b/contrib/libs/openssl/crypto/evp/e_camellia.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2006-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2006-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -55,16 +55,16 @@ void cmll_t4_decrypt(const unsigned char *in, unsigned char *out,
void cmll128_t4_cbc_encrypt(const unsigned char *in, unsigned char *out,
size_t len, const CAMELLIA_KEY *key,
- unsigned char *ivec, int /*unused*/);
+ unsigned char *ivec, int /*unused*/);
void cmll128_t4_cbc_decrypt(const unsigned char *in, unsigned char *out,
size_t len, const CAMELLIA_KEY *key,
- unsigned char *ivec, int /*unused*/);
+ unsigned char *ivec, int /*unused*/);
void cmll256_t4_cbc_encrypt(const unsigned char *in, unsigned char *out,
size_t len, const CAMELLIA_KEY *key,
- unsigned char *ivec, int /*unused*/);
+ unsigned char *ivec, int /*unused*/);
void cmll256_t4_cbc_decrypt(const unsigned char *in, unsigned char *out,
size_t len, const CAMELLIA_KEY *key,
- unsigned char *ivec, int /*unused*/);
+ unsigned char *ivec, int /*unused*/);
void cmll128_t4_ctr32_encrypt(const unsigned char *in, unsigned char *out,
size_t blocks, const CAMELLIA_KEY *key,
unsigned char *ivec);
diff --git a/contrib/libs/openssl/crypto/evp/encode.c b/contrib/libs/openssl/crypto/evp/encode.c
index 4b1b78d7d4..85926434c3 100644
--- a/contrib/libs/openssl/crypto/evp/encode.c
+++ b/contrib/libs/openssl/crypto/evp/encode.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -423,7 +423,7 @@ static int evp_decodeblock_int(EVP_ENCODE_CTX *ctx, unsigned char *t,
table = data_ascii2bin;
/* trim white space from the start of the line. */
- while ((n > 0) && (conv_ascii2bin(*f, table) == B64_WS)) {
+ while ((n > 0) && (conv_ascii2bin(*f, table) == B64_WS)) {
f++;
n--;
}
diff --git a/contrib/libs/openssl/crypto/evp/evp_enc.c b/contrib/libs/openssl/crypto/evp/evp_enc.c
index fd220f74ea..e3c165d48e 100644
--- a/contrib/libs/openssl/crypto/evp/evp_enc.c
+++ b/contrib/libs/openssl/crypto/evp/evp_enc.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -8,7 +8,7 @@
*/
#include <stdio.h>
-#include <limits.h>
+#include <limits.h>
#include <assert.h>
#include "internal/cryptlib.h"
#include <openssl/evp.h>
@@ -356,19 +356,19 @@ static int evp_EncryptDecryptUpdate(EVP_CIPHER_CTX *ctx,
return 1;
} else {
j = bl - i;
-
- /*
- * Once we've processed the first j bytes from in, the amount of
- * data left that is a multiple of the block length is:
- * (inl - j) & ~(bl - 1)
- * We must ensure that this amount of data, plus the one block that
- * we process from ctx->buf does not exceed INT_MAX
- */
- if (((inl - j) & ~(bl - 1)) > INT_MAX - bl) {
- EVPerr(EVP_F_EVP_ENCRYPTDECRYPTUPDATE,
- EVP_R_OUTPUT_WOULD_OVERFLOW);
- return 0;
- }
+
+ /*
+ * Once we've processed the first j bytes from in, the amount of
+ * data left that is a multiple of the block length is:
+ * (inl - j) & ~(bl - 1)
+ * We must ensure that this amount of data, plus the one block that
+ * we process from ctx->buf does not exceed INT_MAX
+ */
+ if (((inl - j) & ~(bl - 1)) > INT_MAX - bl) {
+ EVPerr(EVP_F_EVP_ENCRYPTDECRYPTUPDATE,
+ EVP_R_OUTPUT_WOULD_OVERFLOW);
+ return 0;
+ }
memcpy(&(ctx->buf[i]), in, j);
inl -= j;
in += j;
@@ -516,19 +516,19 @@ int EVP_DecryptUpdate(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl,
EVPerr(EVP_F_EVP_DECRYPTUPDATE, EVP_R_PARTIALLY_OVERLAPPING);
return 0;
}
- /*
- * final_used is only ever set if buf_len is 0. Therefore the maximum
- * length output we will ever see from evp_EncryptDecryptUpdate is
- * the maximum multiple of the block length that is <= inl, or just:
- * inl & ~(b - 1)
- * Since final_used has been set then the final output length is:
- * (inl & ~(b - 1)) + b
- * This must never exceed INT_MAX
- */
- if ((inl & ~(b - 1)) > INT_MAX - b) {
- EVPerr(EVP_F_EVP_DECRYPTUPDATE, EVP_R_OUTPUT_WOULD_OVERFLOW);
- return 0;
- }
+ /*
+ * final_used is only ever set if buf_len is 0. Therefore the maximum
+ * length output we will ever see from evp_EncryptDecryptUpdate is
+ * the maximum multiple of the block length that is <= inl, or just:
+ * inl & ~(b - 1)
+ * Since final_used has been set then the final output length is:
+ * (inl & ~(b - 1)) + b
+ * This must never exceed INT_MAX
+ */
+ if ((inl & ~(b - 1)) > INT_MAX - b) {
+ EVPerr(EVP_F_EVP_DECRYPTUPDATE, EVP_R_OUTPUT_WOULD_OVERFLOW);
+ return 0;
+ }
memcpy(out, ctx->final, b);
out += b;
fix_len = 1;
diff --git a/contrib/libs/openssl/crypto/evp/evp_err.c b/contrib/libs/openssl/crypto/evp/evp_err.c
index cd04f529ea..32ac0125de 100644
--- a/contrib/libs/openssl/crypto/evp/evp_err.c
+++ b/contrib/libs/openssl/crypto/evp/evp_err.c
@@ -1,6 +1,6 @@
/*
* Generated by util/mkerr.pl DO NOT EDIT
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -239,8 +239,8 @@ static const ERR_STRING_DATA EVP_str_reasons[] = {
"operation not supported for this keytype"},
{ERR_PACK(ERR_LIB_EVP, 0, EVP_R_OPERATON_NOT_INITIALIZED),
"operaton not initialized"},
- {ERR_PACK(ERR_LIB_EVP, 0, EVP_R_OUTPUT_WOULD_OVERFLOW),
- "output would overflow"},
+ {ERR_PACK(ERR_LIB_EVP, 0, EVP_R_OUTPUT_WOULD_OVERFLOW),
+ "output would overflow"},
{ERR_PACK(ERR_LIB_EVP, 0, EVP_R_PARTIALLY_OVERLAPPING),
"partially overlapping buffers"},
{ERR_PACK(ERR_LIB_EVP, 0, EVP_R_PBKDF2_ERROR), "pbkdf2 error"},
diff --git a/contrib/libs/openssl/crypto/hmac/hm_ameth.c b/contrib/libs/openssl/crypto/hmac/hm_ameth.c
index f526b28898..f871e4fe71 100644
--- a/contrib/libs/openssl/crypto/hmac/hm_ameth.c
+++ b/contrib/libs/openssl/crypto/hmac/hm_ameth.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2007-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2007-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -47,8 +47,8 @@ static int hmac_pkey_ctrl(EVP_PKEY *pkey, int op, long arg1, void *arg2)
static int hmac_pkey_public_cmp(const EVP_PKEY *a, const EVP_PKEY *b)
{
- /* the ameth pub_cmp must return 1 on match, 0 on mismatch */
- return ASN1_OCTET_STRING_cmp(EVP_PKEY_get0(a), EVP_PKEY_get0(b)) == 0;
+ /* the ameth pub_cmp must return 1 on match, 0 on mismatch */
+ return ASN1_OCTET_STRING_cmp(EVP_PKEY_get0(a), EVP_PKEY_get0(b)) == 0;
}
static int hmac_set_priv_key(EVP_PKEY *pkey, const unsigned char *priv,
diff --git a/contrib/libs/openssl/crypto/mem_sec.c b/contrib/libs/openssl/crypto/mem_sec.c
index 4692138927..222c786cba 100644
--- a/contrib/libs/openssl/crypto/mem_sec.c
+++ b/contrib/libs/openssl/crypto/mem_sec.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2015-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2015-2020 The OpenSSL Project Authors. All Rights Reserved.
* Copyright 2004-2014, Akamai Technologies. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
@@ -34,12 +34,12 @@
# include <errno.h>
# endif
# endif
-# if defined(__FreeBSD__)
-# define MADV_DONTDUMP MADV_NOCORE
-# endif
-# if !defined(MAP_CONCEAL)
-# define MAP_CONCEAL 0
-# endif
+# if defined(__FreeBSD__)
+# define MADV_DONTDUMP MADV_NOCORE
+# endif
+# if !defined(MAP_CONCEAL)
+# define MAP_CONCEAL 0
+# endif
# include <sys/param.h>
# include <sys/stat.h>
# include <fcntl.h>
@@ -448,7 +448,7 @@ static int sh_init(size_t size, int minsize)
if (1) {
#ifdef MAP_ANON
sh.map_result = mmap(NULL, sh.map_size,
- PROT_READ|PROT_WRITE, MAP_ANON|MAP_PRIVATE|MAP_CONCEAL, -1, 0);
+ PROT_READ|PROT_WRITE, MAP_ANON|MAP_PRIVATE|MAP_CONCEAL, -1, 0);
} else {
#endif
int fd;
@@ -508,7 +508,7 @@ static void sh_done(void)
OPENSSL_free(sh.freelist);
OPENSSL_free(sh.bittable);
OPENSSL_free(sh.bitmalloc);
- if (sh.map_result != MAP_FAILED && sh.map_size)
+ if (sh.map_result != MAP_FAILED && sh.map_size)
munmap(sh.map_result, sh.map_size);
memset(&sh, 0, sizeof(sh));
}
diff --git a/contrib/libs/openssl/crypto/modes/cbc128.c b/contrib/libs/openssl/crypto/modes/cbc128.c
index d1d63f42b7..15a14be708 100644
--- a/contrib/libs/openssl/crypto/modes/cbc128.c
+++ b/contrib/libs/openssl/crypto/modes/cbc128.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2008-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2008-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -15,12 +15,12 @@
# define STRICT_ALIGNMENT 0
#endif
-#if defined(__GNUC__) && !STRICT_ALIGNMENT
-typedef size_t size_t_aX __attribute((__aligned__(1)));
-#else
-typedef size_t size_t_aX;
-#endif
-
+#if defined(__GNUC__) && !STRICT_ALIGNMENT
+typedef size_t size_t_aX __attribute((__aligned__(1)));
+#else
+typedef size_t size_t_aX;
+#endif
+
void CRYPTO_cbc128_encrypt(const unsigned char *in, unsigned char *out,
size_t len, const void *key,
unsigned char ivec[16], block128_f block)
@@ -46,8 +46,8 @@ void CRYPTO_cbc128_encrypt(const unsigned char *in, unsigned char *out,
} else {
while (len >= 16) {
for (n = 0; n < 16; n += sizeof(size_t))
- *(size_t_aX *)(out + n) =
- *(size_t_aX *)(in + n) ^ *(size_t_aX *)(iv + n);
+ *(size_t_aX *)(out + n) =
+ *(size_t_aX *)(in + n) ^ *(size_t_aX *)(iv + n);
(*block) (out, out, key);
iv = out;
len -= 16;
@@ -69,8 +69,8 @@ void CRYPTO_cbc128_encrypt(const unsigned char *in, unsigned char *out,
in += 16;
out += 16;
}
- if (ivec != iv)
- memcpy(ivec, iv, 16);
+ if (ivec != iv)
+ memcpy(ivec, iv, 16);
}
void CRYPTO_cbc128_decrypt(const unsigned char *in, unsigned char *out,
@@ -103,8 +103,8 @@ void CRYPTO_cbc128_decrypt(const unsigned char *in, unsigned char *out,
}
} else if (16 % sizeof(size_t) == 0) { /* always true */
while (len >= 16) {
- size_t_aX *out_t = (size_t_aX *)out;
- size_t_aX *iv_t = (size_t_aX *)iv;
+ size_t_aX *out_t = (size_t_aX *)out;
+ size_t_aX *iv_t = (size_t_aX *)iv;
(*block) (in, out, key);
for (n = 0; n < 16 / sizeof(size_t); n++)
@@ -115,8 +115,8 @@ void CRYPTO_cbc128_decrypt(const unsigned char *in, unsigned char *out,
out += 16;
}
}
- if (ivec != iv)
- memcpy(ivec, iv, 16);
+ if (ivec != iv)
+ memcpy(ivec, iv, 16);
} else {
if (STRICT_ALIGNMENT &&
((size_t)in | (size_t)out | (size_t)ivec) % sizeof(size_t) != 0) {
@@ -134,10 +134,10 @@ void CRYPTO_cbc128_decrypt(const unsigned char *in, unsigned char *out,
}
} else if (16 % sizeof(size_t) == 0) { /* always true */
while (len >= 16) {
- size_t c;
- size_t_aX *out_t = (size_t_aX *)out;
- size_t_aX *ivec_t = (size_t_aX *)ivec;
- const size_t_aX *in_t = (const size_t_aX *)in;
+ size_t c;
+ size_t_aX *out_t = (size_t_aX *)out;
+ size_t_aX *ivec_t = (size_t_aX *)ivec;
+ const size_t_aX *in_t = (const size_t_aX *)in;
(*block) (in, tmp.c, key);
for (n = 0; n < 16 / sizeof(size_t); n++) {
diff --git a/contrib/libs/openssl/crypto/modes/ccm128.c b/contrib/libs/openssl/crypto/modes/ccm128.c
index 69e10522a1..655b103502 100644
--- a/contrib/libs/openssl/crypto/modes/ccm128.c
+++ b/contrib/libs/openssl/crypto/modes/ccm128.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2011-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2011-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -11,14 +11,14 @@
#include "modes_local.h"
#include <string.h>
-#ifndef STRICT_ALIGNMENT
-# ifdef __GNUC__
-typedef u64 u64_a1 __attribute((__aligned__(1)));
-# else
-typedef u64 u64_a1;
-# endif
-#endif
-
+#ifndef STRICT_ALIGNMENT
+# ifdef __GNUC__
+typedef u64 u64_a1 __attribute((__aligned__(1)));
+# else
+typedef u64 u64_a1;
+# endif
+#endif
+
/*
* First you setup M and L parameters and pass the key schedule. This is
* called once per session setup...
@@ -178,8 +178,8 @@ int CRYPTO_ccm128_encrypt(CCM128_CONTEXT *ctx,
ctx->cmac.u[0] ^= temp.u[0];
ctx->cmac.u[1] ^= temp.u[1];
#else
- ctx->cmac.u[0] ^= ((u64_a1 *)inp)[0];
- ctx->cmac.u[1] ^= ((u64_a1 *)inp)[1];
+ ctx->cmac.u[0] ^= ((u64_a1 *)inp)[0];
+ ctx->cmac.u[1] ^= ((u64_a1 *)inp)[1];
#endif
(*block) (ctx->cmac.c, ctx->cmac.c, key);
(*block) (ctx->nonce.c, scratch.c, key);
@@ -189,8 +189,8 @@ int CRYPTO_ccm128_encrypt(CCM128_CONTEXT *ctx,
temp.u[1] ^= scratch.u[1];
memcpy(out, temp.c, 16);
#else
- ((u64_a1 *)out)[0] = scratch.u[0] ^ ((u64_a1 *)inp)[0];
- ((u64_a1 *)out)[1] = scratch.u[1] ^ ((u64_a1 *)inp)[1];
+ ((u64_a1 *)out)[0] = scratch.u[0] ^ ((u64_a1 *)inp)[0];
+ ((u64_a1 *)out)[1] = scratch.u[1] ^ ((u64_a1 *)inp)[1];
#endif
inp += 16;
out += 16;
@@ -262,10 +262,10 @@ int CRYPTO_ccm128_decrypt(CCM128_CONTEXT *ctx,
ctx->cmac.u[1] ^= (scratch.u[1] ^= temp.u[1]);
memcpy(out, scratch.c, 16);
#else
- ctx->cmac.u[0] ^= (((u64_a1 *)out)[0]
- = scratch.u[0] ^ ((u64_a1 *)inp)[0]);
- ctx->cmac.u[1] ^= (((u64_a1 *)out)[1]
- = scratch.u[1] ^ ((u64_a1 *)inp)[1]);
+ ctx->cmac.u[0] ^= (((u64_a1 *)out)[0]
+ = scratch.u[0] ^ ((u64_a1 *)inp)[0]);
+ ctx->cmac.u[1] ^= (((u64_a1 *)out)[1]
+ = scratch.u[1] ^ ((u64_a1 *)inp)[1]);
#endif
(*block) (ctx->cmac.c, ctx->cmac.c, key);
diff --git a/contrib/libs/openssl/crypto/modes/cfb128.c b/contrib/libs/openssl/crypto/modes/cfb128.c
index 4506b9a3d9..b2530007b6 100644
--- a/contrib/libs/openssl/crypto/modes/cfb128.c
+++ b/contrib/libs/openssl/crypto/modes/cfb128.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2008-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2008-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -11,12 +11,12 @@
#include "modes_local.h"
#include <string.h>
-#if defined(__GNUC__) && !defined(STRICT_ALIGNMENT)
-typedef size_t size_t_aX __attribute((__aligned__(1)));
-#else
-typedef size_t size_t_aX;
-#endif
-
+#if defined(__GNUC__) && !defined(STRICT_ALIGNMENT)
+typedef size_t size_t_aX __attribute((__aligned__(1)));
+#else
+typedef size_t size_t_aX;
+#endif
+
/*
* The input and output encrypted as though 128bit cfb mode is being used.
* The extra state information to record how much of the 128bit block we have
@@ -49,9 +49,9 @@ void CRYPTO_cfb128_encrypt(const unsigned char *in, unsigned char *out,
while (len >= 16) {
(*block) (ivec, ivec, key);
for (; n < 16; n += sizeof(size_t)) {
- *(size_t_aX *)(out + n) =
- *(size_t_aX *)(ivec + n)
- ^= *(size_t_aX *)(in + n);
+ *(size_t_aX *)(out + n) =
+ *(size_t_aX *)(ivec + n)
+ ^= *(size_t_aX *)(in + n);
}
len -= 16;
out += 16;
@@ -99,10 +99,10 @@ void CRYPTO_cfb128_encrypt(const unsigned char *in, unsigned char *out,
while (len >= 16) {
(*block) (ivec, ivec, key);
for (; n < 16; n += sizeof(size_t)) {
- size_t t = *(size_t_aX *)(in + n);
- *(size_t_aX *)(out + n)
- = *(size_t_aX *)(ivec + n) ^ t;
- *(size_t_aX *)(ivec + n) = t;
+ size_t t = *(size_t_aX *)(in + n);
+ *(size_t_aX *)(out + n)
+ = *(size_t_aX *)(ivec + n) ^ t;
+ *(size_t_aX *)(ivec + n) = t;
}
len -= 16;
out += 16;
diff --git a/contrib/libs/openssl/crypto/modes/ctr128.c b/contrib/libs/openssl/crypto/modes/ctr128.c
index f64a1317a3..1ed7decedf 100644
--- a/contrib/libs/openssl/crypto/modes/ctr128.c
+++ b/contrib/libs/openssl/crypto/modes/ctr128.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2008-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2008-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -11,12 +11,12 @@
#include "modes_local.h"
#include <string.h>
-#if defined(__GNUC__) && !defined(STRICT_ALIGNMENT)
-typedef size_t size_t_aX __attribute((__aligned__(1)));
-#else
-typedef size_t size_t_aX;
-#endif
-
+#if defined(__GNUC__) && !defined(STRICT_ALIGNMENT)
+typedef size_t size_t_aX __attribute((__aligned__(1)));
+#else
+typedef size_t size_t_aX;
+#endif
+
/*
* NOTE: the IV/counter CTR mode is big-endian. The code itself is
* endian-neutral.
@@ -103,9 +103,9 @@ void CRYPTO_ctr128_encrypt(const unsigned char *in, unsigned char *out,
(*block) (ivec, ecount_buf, key);
ctr128_inc_aligned(ivec);
for (n = 0; n < 16; n += sizeof(size_t))
- *(size_t_aX *)(out + n) =
- *(size_t_aX *)(in + n)
- ^ *(size_t_aX *)(ecount_buf + n);
+ *(size_t_aX *)(out + n) =
+ *(size_t_aX *)(in + n)
+ ^ *(size_t_aX *)(ecount_buf + n);
len -= 16;
out += 16;
in += 16;
diff --git a/contrib/libs/openssl/crypto/modes/gcm128.c b/contrib/libs/openssl/crypto/modes/gcm128.c
index c1df3e5e61..8304efff48 100644
--- a/contrib/libs/openssl/crypto/modes/gcm128.c
+++ b/contrib/libs/openssl/crypto/modes/gcm128.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2010-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2010-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -11,12 +11,12 @@
#include "modes_local.h"
#include <string.h>
-#if defined(__GNUC__) && !defined(STRICT_ALIGNMENT)
-typedef size_t size_t_aX __attribute((__aligned__(1)));
-#else
-typedef size_t size_t_aX;
-#endif
-
+#if defined(__GNUC__) && !defined(STRICT_ALIGNMENT)
+typedef size_t size_t_aX __attribute((__aligned__(1)));
+#else
+typedef size_t size_t_aX;
+#endif
+
#if defined(BSWAP4) && defined(STRICT_ALIGNMENT)
/* redefine, because alignment is ensured */
# undef GETU32
@@ -1086,8 +1086,8 @@ int CRYPTO_gcm128_encrypt(GCM128_CONTEXT *ctx,
size_t j = GHASH_CHUNK;
while (j) {
- size_t_aX *out_t = (size_t_aX *)out;
- const size_t_aX *in_t = (const size_t_aX *)in;
+ size_t_aX *out_t = (size_t_aX *)out;
+ const size_t_aX *in_t = (const size_t_aX *)in;
(*block) (ctx->Yi.c, ctx->EKi.c, key);
++ctr;
@@ -1113,8 +1113,8 @@ int CRYPTO_gcm128_encrypt(GCM128_CONTEXT *ctx,
size_t j = i;
while (len >= 16) {
- size_t_aX *out_t = (size_t_aX *)out;
- const size_t_aX *in_t = (const size_t_aX *)in;
+ size_t_aX *out_t = (size_t_aX *)out;
+ const size_t_aX *in_t = (const size_t_aX *)in;
(*block) (ctx->Yi.c, ctx->EKi.c, key);
++ctr;
@@ -1324,8 +1324,8 @@ int CRYPTO_gcm128_decrypt(GCM128_CONTEXT *ctx,
GHASH(ctx, in, GHASH_CHUNK);
while (j) {
- size_t_aX *out_t = (size_t_aX *)out;
- const size_t_aX *in_t = (const size_t_aX *)in;
+ size_t_aX *out_t = (size_t_aX *)out;
+ const size_t_aX *in_t = (const size_t_aX *)in;
(*block) (ctx->Yi.c, ctx->EKi.c, key);
++ctr;
@@ -1349,8 +1349,8 @@ int CRYPTO_gcm128_decrypt(GCM128_CONTEXT *ctx,
if ((i = (len & (size_t)-16))) {
GHASH(ctx, in, i);
while (len >= 16) {
- size_t_aX *out_t = (size_t_aX *)out;
- const size_t_aX *in_t = (const size_t_aX *)in;
+ size_t_aX *out_t = (size_t_aX *)out;
+ const size_t_aX *in_t = (const size_t_aX *)in;
(*block) (ctx->Yi.c, ctx->EKi.c, key);
++ctr;
@@ -1385,8 +1385,8 @@ int CRYPTO_gcm128_decrypt(GCM128_CONTEXT *ctx,
else
ctx->Yi.d[3] = ctr;
for (i = 0; i < 16 / sizeof(size_t); ++i) {
- size_t c = in_t[i];
- out_t[i] = c ^ ctx->EKi.t[i];
+ size_t c = in_t[i];
+ out_t[i] = c ^ ctx->EKi.t[i];
ctx->Xi.t[i] ^= c;
}
GCM_MUL(ctx);
diff --git a/contrib/libs/openssl/crypto/modes/modes_local.h b/contrib/libs/openssl/crypto/modes/modes_local.h
index 65865c802b..888141681e 100644
--- a/contrib/libs/openssl/crypto/modes/modes_local.h
+++ b/contrib/libs/openssl/crypto/modes/modes_local.h
@@ -1,5 +1,5 @@
/*
- * Copyright 2010-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2010-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -37,14 +37,14 @@ typedef unsigned char u8;
# endif
#endif
-#ifndef STRICT_ALIGNMENT
-# ifdef __GNUC__
-typedef u32 u32_a1 __attribute((__aligned__(1)));
-# else
-typedef u32 u32_a1;
-# endif
-#endif
-
+#ifndef STRICT_ALIGNMENT
+# ifdef __GNUC__
+typedef u32 u32_a1 __attribute((__aligned__(1)));
+# else
+typedef u32 u32_a1;
+# endif
+#endif
+
#if !defined(PEDANTIC) && !defined(OPENSSL_NO_ASM) && !defined(OPENSSL_NO_INLINE_ASM)
# if defined(__GNUC__) && __GNUC__>=2
# if defined(__x86_64) || defined(__x86_64__)
@@ -63,15 +63,15 @@ typedef u32 u32_a1;
asm ("bswapl %0" \
: "+r"(ret_)); ret_; })
# elif defined(__aarch64__)
-# if defined(__BYTE_ORDER__) && defined(__ORDER_LITTLE_ENDIAN__) && \
- __BYTE_ORDER__==__ORDER_LITTLE_ENDIAN__
-# define BSWAP8(x) ({ u64 ret_; \
+# if defined(__BYTE_ORDER__) && defined(__ORDER_LITTLE_ENDIAN__) && \
+ __BYTE_ORDER__==__ORDER_LITTLE_ENDIAN__
+# define BSWAP8(x) ({ u64 ret_; \
asm ("rev %0,%1" \
: "=r"(ret_) : "r"(x)); ret_; })
-# define BSWAP4(x) ({ u32 ret_; \
+# define BSWAP4(x) ({ u32 ret_; \
asm ("rev %w0,%w1" \
: "=r"(ret_) : "r"(x)); ret_; })
-# endif
+# endif
# elif (defined(__arm__) || defined(__arm)) && !defined(STRICT_ALIGNMENT)
# define BSWAP8(x) ({ u32 lo_=(u64)(x)>>32,hi_=(x); \
asm ("rev %0,%0; rev %1,%1" \
@@ -97,8 +97,8 @@ _asm mov eax, val _asm bswap eax}
# endif
#endif
#if defined(BSWAP4) && !defined(STRICT_ALIGNMENT)
-# define GETU32(p) BSWAP4(*(const u32_a1 *)(p))
-# define PUTU32(p,v) *(u32_a1 *)(p) = BSWAP4(v)
+# define GETU32(p) BSWAP4(*(const u32_a1 *)(p))
+# define PUTU32(p,v) *(u32_a1 *)(p) = BSWAP4(v)
#else
# define GETU32(p) ((u32)(p)[0]<<24|(u32)(p)[1]<<16|(u32)(p)[2]<<8|(u32)(p)[3])
# define PUTU32(p,v) ((p)[0]=(u8)((v)>>24),(p)[1]=(u8)((v)>>16),(p)[2]=(u8)((v)>>8),(p)[3]=(u8)(v))
diff --git a/contrib/libs/openssl/crypto/modes/ofb128.c b/contrib/libs/openssl/crypto/modes/ofb128.c
index f4ef44b0b9..a3469712b2 100644
--- a/contrib/libs/openssl/crypto/modes/ofb128.c
+++ b/contrib/libs/openssl/crypto/modes/ofb128.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2008-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2008-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -11,12 +11,12 @@
#include "modes_local.h"
#include <string.h>
-#if defined(__GNUC__) && !defined(STRICT_ALIGNMENT)
-typedef size_t size_t_aX __attribute((__aligned__(1)));
-#else
-typedef size_t size_t_aX;
-#endif
-
+#if defined(__GNUC__) && !defined(STRICT_ALIGNMENT)
+typedef size_t size_t_aX __attribute((__aligned__(1)));
+#else
+typedef size_t size_t_aX;
+#endif
+
/*
* The input and output encrypted as though 128bit ofb mode is being used.
* The extra state information to record how much of the 128bit block we have
@@ -47,9 +47,9 @@ void CRYPTO_ofb128_encrypt(const unsigned char *in, unsigned char *out,
while (len >= 16) {
(*block) (ivec, ivec, key);
for (; n < 16; n += sizeof(size_t))
- *(size_t_aX *)(out + n) =
- *(size_t_aX *)(in + n)
- ^ *(size_t_aX *)(ivec + n);
+ *(size_t_aX *)(out + n) =
+ *(size_t_aX *)(in + n)
+ ^ *(size_t_aX *)(ivec + n);
len -= 16;
out += 16;
in += 16;
diff --git a/contrib/libs/openssl/crypto/modes/xts128.c b/contrib/libs/openssl/crypto/modes/xts128.c
index 89a0871ea0..fe1626c62e 100644
--- a/contrib/libs/openssl/crypto/modes/xts128.c
+++ b/contrib/libs/openssl/crypto/modes/xts128.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2011-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2011-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -11,14 +11,14 @@
#include "modes_local.h"
#include <string.h>
-#ifndef STRICT_ALIGNMENT
-# ifdef __GNUC__
-typedef u64 u64_a1 __attribute((__aligned__(1)));
-# else
-typedef u64 u64_a1;
-# endif
-#endif
-
+#ifndef STRICT_ALIGNMENT
+# ifdef __GNUC__
+typedef u64 u64_a1 __attribute((__aligned__(1)));
+# else
+typedef u64 u64_a1;
+# endif
+#endif
+
int CRYPTO_xts128_encrypt(const XTS128_CONTEXT *ctx,
const unsigned char iv[16],
const unsigned char *inp, unsigned char *out,
@@ -53,8 +53,8 @@ int CRYPTO_xts128_encrypt(const XTS128_CONTEXT *ctx,
scratch.u[0] ^= tweak.u[0];
scratch.u[1] ^= tweak.u[1];
#else
- scratch.u[0] = ((u64_a1 *)inp)[0] ^ tweak.u[0];
- scratch.u[1] = ((u64_a1 *)inp)[1] ^ tweak.u[1];
+ scratch.u[0] = ((u64_a1 *)inp)[0] ^ tweak.u[0];
+ scratch.u[1] = ((u64_a1 *)inp)[1] ^ tweak.u[1];
#endif
(*ctx->block1) (scratch.c, scratch.c, ctx->key1);
#if defined(STRICT_ALIGNMENT)
@@ -62,8 +62,8 @@ int CRYPTO_xts128_encrypt(const XTS128_CONTEXT *ctx,
scratch.u[1] ^= tweak.u[1];
memcpy(out, scratch.c, 16);
#else
- ((u64_a1 *)out)[0] = scratch.u[0] ^= tweak.u[0];
- ((u64_a1 *)out)[1] = scratch.u[1] ^= tweak.u[1];
+ ((u64_a1 *)out)[0] = scratch.u[0] ^= tweak.u[0];
+ ((u64_a1 *)out)[1] = scratch.u[1] ^= tweak.u[1];
#endif
inp += 16;
out += 16;
@@ -136,8 +136,8 @@ int CRYPTO_xts128_encrypt(const XTS128_CONTEXT *ctx,
scratch.u[0] ^= tweak1.u[0];
scratch.u[1] ^= tweak1.u[1];
#else
- scratch.u[0] = ((u64_a1 *)inp)[0] ^ tweak1.u[0];
- scratch.u[1] = ((u64_a1 *)inp)[1] ^ tweak1.u[1];
+ scratch.u[0] = ((u64_a1 *)inp)[0] ^ tweak1.u[0];
+ scratch.u[1] = ((u64_a1 *)inp)[1] ^ tweak1.u[1];
#endif
(*ctx->block1) (scratch.c, scratch.c, ctx->key1);
scratch.u[0] ^= tweak1.u[0];
@@ -156,8 +156,8 @@ int CRYPTO_xts128_encrypt(const XTS128_CONTEXT *ctx,
scratch.u[1] ^= tweak.u[1];
memcpy(out, scratch.c, 16);
#else
- ((u64_a1 *)out)[0] = scratch.u[0] ^ tweak.u[0];
- ((u64_a1 *)out)[1] = scratch.u[1] ^ tweak.u[1];
+ ((u64_a1 *)out)[0] = scratch.u[0] ^ tweak.u[0];
+ ((u64_a1 *)out)[1] = scratch.u[1] ^ tweak.u[1];
#endif
}
diff --git a/contrib/libs/openssl/crypto/o_str.c b/contrib/libs/openssl/crypto/o_str.c
index e8cd22eff7..eb9f21cc0c 100644
--- a/contrib/libs/openssl/crypto/o_str.c
+++ b/contrib/libs/openssl/crypto/o_str.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2003-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2003-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -220,7 +220,7 @@ char *OPENSSL_buf2hexstr(const unsigned char *buffer, long len)
int openssl_strerror_r(int errnum, char *buf, size_t buflen)
{
-#if defined(_MSC_VER) && _MSC_VER>=1400 && !defined(_WIN32_WCE)
+#if defined(_MSC_VER) && _MSC_VER>=1400 && !defined(_WIN32_WCE)
return !strerror_s(buf, buflen, errnum);
#elif defined(_GNU_SOURCE)
char *err;
diff --git a/contrib/libs/openssl/crypto/o_time.c b/contrib/libs/openssl/crypto/o_time.c
index 8351ca00f6..3fa70c45af 100644
--- a/contrib/libs/openssl/crypto/o_time.c
+++ b/contrib/libs/openssl/crypto/o_time.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2001-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2001-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -41,7 +41,7 @@ struct tm *OPENSSL_gmtime(const time_t *timer, struct tm *result)
if (gmtime_r(timer, result) == NULL)
return NULL;
ts = result;
-#elif defined (OPENSSL_SYS_WINDOWS) && defined(_MSC_VER) && _MSC_VER >= 1400 && !defined(_WIN32_WCE)
+#elif defined (OPENSSL_SYS_WINDOWS) && defined(_MSC_VER) && _MSC_VER >= 1400 && !defined(_WIN32_WCE)
if (gmtime_s(result, timer))
return NULL;
ts = result;
@@ -133,8 +133,8 @@ int OPENSSL_gmtime_diff(int *pday, int *psec,
static int julian_adj(const struct tm *tm, int off_day, long offset_sec,
long *pday, int *psec)
{
- int offset_hms;
- long offset_day, time_jd;
+ int offset_hms;
+ long offset_day, time_jd;
int time_year, time_month, time_day;
/* split offset into days and day seconds */
offset_day = offset_sec / SECS_PER_DAY;
diff --git a/contrib/libs/openssl/crypto/objects/README b/contrib/libs/openssl/crypto/objects/README
index 0c7a6ca4aa..700f9c5e54 100644
--- a/contrib/libs/openssl/crypto/objects/README
+++ b/contrib/libs/openssl/crypto/objects/README
@@ -1,44 +1,44 @@
-objects.txt syntax
-------------------
-
-To cover all the naming hacks that were previously in objects.h needed some
-kind of hacks in objects.txt.
-
-The basic syntax for adding an object is as follows:
-
- 1 2 3 4 : shortName : Long Name
-
- If Long Name contains only word characters and hyphen-minus
- (0x2D) or full stop (0x2E) then Long Name is used as basis
- for the base name in C. Otherwise, the shortName is used.
-
- The base name (let's call it 'base') will then be used to
- create the C macros SN_base, LN_base, NID_base and OBJ_base.
-
- Note that if the base name contains spaces, dashes or periods,
- those will be converted to underscore.
-
-Then there are some extra commands:
-
- !Alias foo 1 2 3 4
-
- This just makes a name foo for an OID. The C macro
- OBJ_foo will be created as a result.
-
- !Cname foo
-
- This makes sure that the name foo will be used as base name
- in C.
-
- !module foo
- 1 2 3 4 : shortName : Long Name
- !global
-
- The !module command was meant to define a kind of modularity.
- What it does is to make sure the module name is prepended
- to the base name. !global turns this off. This construction
- is not recursive.
-
-Lines starting with # are treated as comments, as well as any line starting
-with ! and not matching the commands above.
-
+objects.txt syntax
+------------------
+
+To cover all the naming hacks that were previously in objects.h needed some
+kind of hacks in objects.txt.
+
+The basic syntax for adding an object is as follows:
+
+ 1 2 3 4 : shortName : Long Name
+
+ If Long Name contains only word characters and hyphen-minus
+ (0x2D) or full stop (0x2E) then Long Name is used as basis
+ for the base name in C. Otherwise, the shortName is used.
+
+ The base name (let's call it 'base') will then be used to
+ create the C macros SN_base, LN_base, NID_base and OBJ_base.
+
+ Note that if the base name contains spaces, dashes or periods,
+ those will be converted to underscore.
+
+Then there are some extra commands:
+
+ !Alias foo 1 2 3 4
+
+ This just makes a name foo for an OID. The C macro
+ OBJ_foo will be created as a result.
+
+ !Cname foo
+
+ This makes sure that the name foo will be used as base name
+ in C.
+
+ !module foo
+ 1 2 3 4 : shortName : Long Name
+ !global
+
+ The !module command was meant to define a kind of modularity.
+ What it does is to make sure the module name is prepended
+ to the base name. !global turns this off. This construction
+ is not recursive.
+
+Lines starting with # are treated as comments, as well as any line starting
+with ! and not matching the commands above.
+
diff --git a/contrib/libs/openssl/crypto/objects/obj_dat.h b/contrib/libs/openssl/crypto/objects/obj_dat.h
index 5b9afdc776..24b49a2df2 100644
--- a/contrib/libs/openssl/crypto/objects/obj_dat.h
+++ b/contrib/libs/openssl/crypto/objects/obj_dat.h
@@ -2,7 +2,7 @@
* WARNING: do not edit!
* Generated by crypto/objects/obj_dat.pl
*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
* Licensed under the OpenSSL license (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
diff --git a/contrib/libs/openssl/crypto/objects/obj_xref.h b/contrib/libs/openssl/crypto/objects/obj_xref.h
index 005aae6968..5c3561ab7d 100644
--- a/contrib/libs/openssl/crypto/objects/obj_xref.h
+++ b/contrib/libs/openssl/crypto/objects/obj_xref.h
@@ -2,7 +2,7 @@
* WARNING: do not edit!
* Generated by objxref.pl
*
- * Copyright 1998-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1998-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
diff --git a/contrib/libs/openssl/crypto/pem/pem_err.c b/contrib/libs/openssl/crypto/pem/pem_err.c
index e4eb7e3499..0f3cb02407 100644
--- a/contrib/libs/openssl/crypto/pem/pem_err.c
+++ b/contrib/libs/openssl/crypto/pem/pem_err.c
@@ -1,6 +1,6 @@
/*
* Generated by util/mkerr.pl DO NOT EDIT
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -60,8 +60,8 @@ static const ERR_STRING_DATA PEM_str_functs[] = {
{ERR_PACK(ERR_LIB_PEM, PEM_F_PEM_SIGNFINAL, 0), "PEM_SignFinal"},
{ERR_PACK(ERR_LIB_PEM, PEM_F_PEM_WRITE, 0), "PEM_write"},
{ERR_PACK(ERR_LIB_PEM, PEM_F_PEM_WRITE_BIO, 0), "PEM_write_bio"},
- {ERR_PACK(ERR_LIB_PEM, PEM_F_PEM_WRITE_BIO_PRIVATEKEY_TRADITIONAL, 0),
- "PEM_write_bio_PrivateKey_traditional"},
+ {ERR_PACK(ERR_LIB_PEM, PEM_F_PEM_WRITE_BIO_PRIVATEKEY_TRADITIONAL, 0),
+ "PEM_write_bio_PrivateKey_traditional"},
{ERR_PACK(ERR_LIB_PEM, PEM_F_PEM_WRITE_PRIVATEKEY, 0),
"PEM_write_PrivateKey"},
{ERR_PACK(ERR_LIB_PEM, PEM_F_PEM_X509_INFO_READ, 0), "PEM_X509_INFO_read"},
@@ -111,8 +111,8 @@ static const ERR_STRING_DATA PEM_str_reasons[] = {
"unsupported encryption"},
{ERR_PACK(ERR_LIB_PEM, 0, PEM_R_UNSUPPORTED_KEY_COMPONENTS),
"unsupported key components"},
- {ERR_PACK(ERR_LIB_PEM, 0, PEM_R_UNSUPPORTED_PUBLIC_KEY_TYPE),
- "unsupported public key type"},
+ {ERR_PACK(ERR_LIB_PEM, 0, PEM_R_UNSUPPORTED_PUBLIC_KEY_TYPE),
+ "unsupported public key type"},
{0, NULL}
};
diff --git a/contrib/libs/openssl/crypto/pem/pem_lib.c b/contrib/libs/openssl/crypto/pem/pem_lib.c
index ed8ccbf01f..a26322119a 100644
--- a/contrib/libs/openssl/crypto/pem/pem_lib.c
+++ b/contrib/libs/openssl/crypto/pem/pem_lib.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -332,7 +332,7 @@ int PEM_ASN1_write_bio(i2d_of_void *i2d, const char *name, BIO *bp,
}
}
- if ((dsize = i2d(x, NULL)) <= 0) {
+ if ((dsize = i2d(x, NULL)) <= 0) {
PEMerr(PEM_F_PEM_ASN1_WRITE_BIO, ERR_R_ASN1_LIB);
dsize = 0;
goto err;
@@ -791,7 +791,7 @@ static int get_header_and_data(BIO *bp, BIO **header, BIO **data, char *name,
{
BIO *tmp = *header;
char *linebuf, *p;
- int len, line, ret = 0, end = 0, prev_partial_line_read = 0, partial_line_read = 0;
+ int len, line, ret = 0, end = 0, prev_partial_line_read = 0, partial_line_read = 0;
/* 0 if not seen (yet), 1 if reading header, 2 if finished header */
enum header_status got_header = MAYBE_HEADER;
unsigned int flags_mask;
@@ -809,18 +809,18 @@ static int get_header_and_data(BIO *bp, BIO **header, BIO **data, char *name,
flags_mask = ~0u;
len = BIO_gets(bp, linebuf, LINESIZE);
if (len <= 0) {
- PEMerr(PEM_F_GET_HEADER_AND_DATA, PEM_R_BAD_END_LINE);
+ PEMerr(PEM_F_GET_HEADER_AND_DATA, PEM_R_BAD_END_LINE);
goto err;
}
- /*
- * Check if line has been read completely or if only part of the line
- * has been read. Keep the previous value to ignore newlines that
- * appear due to reading a line up until the char before the newline.
- */
- prev_partial_line_read = partial_line_read;
- partial_line_read = len == LINESIZE-1 && linebuf[LINESIZE-2] != '\n';
-
+ /*
+ * Check if line has been read completely or if only part of the line
+ * has been read. Keep the previous value to ignore newlines that
+ * appear due to reading a line up until the char before the newline.
+ */
+ prev_partial_line_read = partial_line_read;
+ partial_line_read = len == LINESIZE-1 && linebuf[LINESIZE-2] != '\n';
+
if (got_header == MAYBE_HEADER) {
if (memchr(linebuf, ':', len) != NULL)
got_header = IN_HEADER;
@@ -831,18 +831,18 @@ static int get_header_and_data(BIO *bp, BIO **header, BIO **data, char *name,
/* Check for end of header. */
if (linebuf[0] == '\n') {
- /*
- * If previous line has been read only partially this newline is a
- * regular newline at the end of a line and not an empty line.
- */
- if (!prev_partial_line_read) {
- if (got_header == POST_HEADER) {
- /* Another blank line is an error. */
- PEMerr(PEM_F_GET_HEADER_AND_DATA, PEM_R_BAD_END_LINE);
- goto err;
- }
- got_header = POST_HEADER;
- tmp = *data;
+ /*
+ * If previous line has been read only partially this newline is a
+ * regular newline at the end of a line and not an empty line.
+ */
+ if (!prev_partial_line_read) {
+ if (got_header == POST_HEADER) {
+ /* Another blank line is an error. */
+ PEMerr(PEM_F_GET_HEADER_AND_DATA, PEM_R_BAD_END_LINE);
+ goto err;
+ }
+ got_header = POST_HEADER;
+ tmp = *data;
}
continue;
}
diff --git a/contrib/libs/openssl/crypto/pem/pem_pkey.c b/contrib/libs/openssl/crypto/pem/pem_pkey.c
index 1c2785115c..4a94927244 100644
--- a/contrib/libs/openssl/crypto/pem/pem_pkey.c
+++ b/contrib/libs/openssl/crypto/pem/pem_pkey.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -108,12 +108,12 @@ int PEM_write_bio_PrivateKey_traditional(BIO *bp, EVP_PKEY *x,
pem_password_cb *cb, void *u)
{
char pem_str[80];
-
- if (x->ameth == NULL || x->ameth->old_priv_encode == NULL) {
- PEMerr(PEM_F_PEM_WRITE_BIO_PRIVATEKEY_TRADITIONAL,
- PEM_R_UNSUPPORTED_PUBLIC_KEY_TYPE);
- return 0;
- }
+
+ if (x->ameth == NULL || x->ameth->old_priv_encode == NULL) {
+ PEMerr(PEM_F_PEM_WRITE_BIO_PRIVATEKEY_TRADITIONAL,
+ PEM_R_UNSUPPORTED_PUBLIC_KEY_TYPE);
+ return 0;
+ }
BIO_snprintf(pem_str, 80, "%s PRIVATE KEY", x->ameth->pem_str);
return PEM_ASN1_write_bio((i2d_of_void *)i2d_PrivateKey,
pem_str, bp, x, enc, kstr, klen, cb, u);
diff --git a/contrib/libs/openssl/crypto/pem/pvkfmt.c b/contrib/libs/openssl/crypto/pem/pvkfmt.c
index 4f3bc8dc48..a933b7c181 100644
--- a/contrib/libs/openssl/crypto/pem/pvkfmt.c
+++ b/contrib/libs/openssl/crypto/pem/pvkfmt.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2005-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2005-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -29,10 +29,10 @@ static unsigned int read_ledword(const unsigned char **in)
{
const unsigned char *p = *in;
unsigned int ret;
- ret = (unsigned int)*p++;
- ret |= (unsigned int)*p++ << 8;
- ret |= (unsigned int)*p++ << 16;
- ret |= (unsigned int)*p++ << 24;
+ ret = (unsigned int)*p++;
+ ret |= (unsigned int)*p++ << 8;
+ ret |= (unsigned int)*p++ << 16;
+ ret |= (unsigned int)*p++ << 24;
*in = p;
return ret;
}
@@ -877,7 +877,7 @@ int i2b_PVK_bio(BIO *out, EVP_PKEY *pk, int enclevel,
if (wrlen == outlen) {
return outlen;
}
- PEMerr(PEM_F_I2B_PVK_BIO, PEM_R_BIO_WRITE_FAILURE);
+ PEMerr(PEM_F_I2B_PVK_BIO, PEM_R_BIO_WRITE_FAILURE);
return -1;
}
diff --git a/contrib/libs/openssl/crypto/pkcs12/p12_key.c b/contrib/libs/openssl/crypto/pkcs12/p12_key.c
index d9b43574c7..03eda26642 100644
--- a/contrib/libs/openssl/crypto/pkcs12/p12_key.c
+++ b/contrib/libs/openssl/crypto/pkcs12/p12_key.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -101,7 +101,7 @@ int PKCS12_key_gen_uni(unsigned char *pass, int passlen, unsigned char *salt,
#endif
v = EVP_MD_block_size(md_type);
u = EVP_MD_size(md_type);
- if (u <= 0 || v <= 0)
+ if (u <= 0 || v <= 0)
goto err;
D = OPENSSL_malloc(v);
Ai = OPENSSL_malloc(u);
diff --git a/contrib/libs/openssl/crypto/pkcs7/pk7_smime.c b/contrib/libs/openssl/crypto/pkcs7/pk7_smime.c
index 564da1a8c7..a95db62178 100644
--- a/contrib/libs/openssl/crypto/pkcs7/pk7_smime.c
+++ b/contrib/libs/openssl/crypto/pkcs7/pk7_smime.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1999-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1999-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -301,7 +301,7 @@ int PKCS7_verify(PKCS7 *p7, STACK_OF(X509) *certs, X509_STORE *store,
char *ptr;
long len;
len = BIO_get_mem_data(indata, &ptr);
- tmpin = (len == 0) ? indata : BIO_new_mem_buf(ptr, len);
+ tmpin = (len == 0) ? indata : BIO_new_mem_buf(ptr, len);
if (tmpin == NULL) {
PKCS7err(PKCS7_F_PKCS7_VERIFY, ERR_R_MALLOC_FAILURE);
goto err;
diff --git a/contrib/libs/openssl/crypto/poly1305/poly1305_ameth.c b/contrib/libs/openssl/crypto/poly1305/poly1305_ameth.c
index e157b933b0..0dddf79626 100644
--- a/contrib/libs/openssl/crypto/poly1305/poly1305_ameth.c
+++ b/contrib/libs/openssl/crypto/poly1305/poly1305_ameth.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2007-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2007-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -43,7 +43,7 @@ static int poly1305_pkey_ctrl(EVP_PKEY *pkey, int op, long arg1, void *arg2)
static int poly1305_pkey_public_cmp(const EVP_PKEY *a, const EVP_PKEY *b)
{
- return ASN1_OCTET_STRING_cmp(EVP_PKEY_get0(a), EVP_PKEY_get0(b)) == 0;
+ return ASN1_OCTET_STRING_cmp(EVP_PKEY_get0(a), EVP_PKEY_get0(b)) == 0;
}
static int poly1305_set_priv_key(EVP_PKEY *pkey, const unsigned char *priv,
diff --git a/contrib/libs/openssl/crypto/ppccap.c b/contrib/libs/openssl/crypto/ppccap.c
index e95aa27aaa..eeaa47cc6b 100644
--- a/contrib/libs/openssl/crypto/ppccap.c
+++ b/contrib/libs/openssl/crypto/ppccap.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2009-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2009-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -211,33 +211,33 @@ size_t OPENSSL_instrument_bus2(unsigned int *out, size_t cnt, size_t max)
# if __GLIBC_PREREQ(2, 16)
# include <sys/auxv.h>
# define OSSL_IMPLEMENT_GETAUXVAL
-# elif defined(__ANDROID_API__)
-/* see https://developer.android.google.cn/ndk/guides/cpu-features */
-# if __ANDROID_API__ >= 18
-# include <sys/auxv.h>
-# define OSSL_IMPLEMENT_GETAUXVAL
-# endif
+# elif defined(__ANDROID_API__)
+/* see https://developer.android.google.cn/ndk/guides/cpu-features */
+# if __ANDROID_API__ >= 18
+# include <sys/auxv.h>
+# define OSSL_IMPLEMENT_GETAUXVAL
+# endif
+# endif
+#endif
+
+#if defined(__FreeBSD__)
+# include <sys/param.h>
+# if __FreeBSD_version >= 1200000
+# include <sys/auxv.h>
+# define OSSL_IMPLEMENT_GETAUXVAL
+
+static unsigned long getauxval(unsigned long key)
+{
+ unsigned long val = 0ul;
+
+ if (elf_aux_info((int)key, &val, sizeof(val)) != 0)
+ return 0ul;
+
+ return val;
+}
# endif
#endif
-#if defined(__FreeBSD__)
-# include <sys/param.h>
-# if __FreeBSD_version >= 1200000
-# include <sys/auxv.h>
-# define OSSL_IMPLEMENT_GETAUXVAL
-
-static unsigned long getauxval(unsigned long key)
-{
- unsigned long val = 0ul;
-
- if (elf_aux_info((int)key, &val, sizeof(val)) != 0)
- return 0ul;
-
- return val;
-}
-# endif
-#endif
-
/* I wish <sys/auxv.h> was universally available */
#define HWCAP 16 /* AT_HWCAP */
#define HWCAP_PPC64 (1U << 30)
diff --git a/contrib/libs/openssl/crypto/rand/drbg_ctr.c b/contrib/libs/openssl/crypto/rand/drbg_ctr.c
index 39a3a08345..c8b3bd79bb 100644
--- a/contrib/libs/openssl/crypto/rand/drbg_ctr.c
+++ b/contrib/libs/openssl/crypto/rand/drbg_ctr.c
@@ -15,7 +15,7 @@
#include "modes_local.h"
#include "internal/thread_once.h"
#include "rand_local.h"
-#include "sanitizers.h"
+#include "sanitizers.h"
/*
* Implementation of NIST SP 800-90A CTR DRBG.
@@ -64,15 +64,15 @@ static void ctr_XOR(RAND_DRBG_CTR *ctr, const unsigned char *in, size_t inlen)
* Process a complete block using BCC algorithm of SP 800-90A 10.3.3
*/
__owur static int ctr_BCC_block(RAND_DRBG_CTR *ctr, unsigned char *out,
- const unsigned char *in, int len)
+ const unsigned char *in, int len)
{
int i, outlen = AES_BLOCK_SIZE;
- for (i = 0; i < len; i++)
+ for (i = 0; i < len; i++)
out[i] ^= in[i];
- if (!EVP_CipherUpdate(ctr->ctx_df, out, &outlen, out, len)
- || outlen != len)
+ if (!EVP_CipherUpdate(ctr->ctx_df, out, &outlen, out, len)
+ || outlen != len)
return 0;
return 1;
}
@@ -83,16 +83,16 @@ __owur static int ctr_BCC_block(RAND_DRBG_CTR *ctr, unsigned char *out,
*/
__owur static int ctr_BCC_blocks(RAND_DRBG_CTR *ctr, const unsigned char *in)
{
- unsigned char in_tmp[48];
- unsigned char num_of_blk = 2;
-
- memcpy(in_tmp, in, 16);
- memcpy(in_tmp + 16, in, 16);
- if (ctr->keylen != 16) {
- memcpy(in_tmp + 32, in, 16);
- num_of_blk = 3;
- }
- return ctr_BCC_block(ctr, ctr->KX, in_tmp, AES_BLOCK_SIZE * num_of_blk);
+ unsigned char in_tmp[48];
+ unsigned char num_of_blk = 2;
+
+ memcpy(in_tmp, in, 16);
+ memcpy(in_tmp + 16, in, 16);
+ if (ctr->keylen != 16) {
+ memcpy(in_tmp + 32, in, 16);
+ num_of_blk = 3;
+ }
+ return ctr_BCC_block(ctr, ctr->KX, in_tmp, AES_BLOCK_SIZE * num_of_blk);
}
/*
@@ -101,14 +101,14 @@ __owur static int ctr_BCC_blocks(RAND_DRBG_CTR *ctr, const unsigned char *in)
*/
__owur static int ctr_BCC_init(RAND_DRBG_CTR *ctr)
{
- unsigned char bltmp[48] = {0};
- unsigned char num_of_blk;
-
+ unsigned char bltmp[48] = {0};
+ unsigned char num_of_blk;
+
memset(ctr->KX, 0, 48);
- num_of_blk = ctr->keylen == 16 ? 2 : 3;
- bltmp[(AES_BLOCK_SIZE * 1) + 3] = 1;
- bltmp[(AES_BLOCK_SIZE * 2) + 3] = 2;
- return ctr_BCC_block(ctr, ctr->KX, bltmp, num_of_blk * AES_BLOCK_SIZE);
+ num_of_blk = ctr->keylen == 16 ? 2 : 3;
+ bltmp[(AES_BLOCK_SIZE * 1) + 3] = 1;
+ bltmp[(AES_BLOCK_SIZE * 2) + 3] = 2;
+ return ctr_BCC_block(ctr, ctr->KX, bltmp, num_of_blk * AES_BLOCK_SIZE);
}
/*
@@ -197,20 +197,20 @@ __owur static int ctr_df(RAND_DRBG_CTR *ctr,
|| !ctr_BCC_final(ctr))
return 0;
/* Set up key K */
- if (!EVP_CipherInit_ex(ctr->ctx_ecb, NULL, NULL, ctr->KX, NULL, -1))
+ if (!EVP_CipherInit_ex(ctr->ctx_ecb, NULL, NULL, ctr->KX, NULL, -1))
return 0;
/* X follows key K */
- if (!EVP_CipherUpdate(ctr->ctx_ecb, ctr->KX, &outlen, ctr->KX + ctr->keylen,
+ if (!EVP_CipherUpdate(ctr->ctx_ecb, ctr->KX, &outlen, ctr->KX + ctr->keylen,
AES_BLOCK_SIZE)
|| outlen != AES_BLOCK_SIZE)
return 0;
- if (!EVP_CipherUpdate(ctr->ctx_ecb, ctr->KX + 16, &outlen, ctr->KX,
+ if (!EVP_CipherUpdate(ctr->ctx_ecb, ctr->KX + 16, &outlen, ctr->KX,
AES_BLOCK_SIZE)
|| outlen != AES_BLOCK_SIZE)
return 0;
if (ctr->keylen != 16)
- if (!EVP_CipherUpdate(ctr->ctx_ecb, ctr->KX + 32, &outlen,
- ctr->KX + 16, AES_BLOCK_SIZE)
+ if (!EVP_CipherUpdate(ctr->ctx_ecb, ctr->KX + 32, &outlen,
+ ctr->KX + 16, AES_BLOCK_SIZE)
|| outlen != AES_BLOCK_SIZE)
return 0;
return 1;
@@ -229,25 +229,25 @@ __owur static int ctr_update(RAND_DRBG *drbg,
{
RAND_DRBG_CTR *ctr = &drbg->data.ctr;
int outlen = AES_BLOCK_SIZE;
- unsigned char V_tmp[48], out[48];
- unsigned char len;
+ unsigned char V_tmp[48], out[48];
+ unsigned char len;
/* correct key is already set up. */
- memcpy(V_tmp, ctr->V, 16);
+ memcpy(V_tmp, ctr->V, 16);
inc_128(ctr);
- memcpy(V_tmp + 16, ctr->V, 16);
- if (ctr->keylen == 16) {
- len = 32;
- } else {
+ memcpy(V_tmp + 16, ctr->V, 16);
+ if (ctr->keylen == 16) {
+ len = 32;
+ } else {
inc_128(ctr);
- memcpy(V_tmp + 32, ctr->V, 16);
- len = 48;
+ memcpy(V_tmp + 32, ctr->V, 16);
+ len = 48;
}
- if (!EVP_CipherUpdate(ctr->ctx_ecb, out, &outlen, V_tmp, len)
- || outlen != len)
+ if (!EVP_CipherUpdate(ctr->ctx_ecb, out, &outlen, V_tmp, len)
+ || outlen != len)
return 0;
- memcpy(ctr->K, out, ctr->keylen);
- memcpy(ctr->V, out + ctr->keylen, 16);
+ memcpy(ctr->K, out, ctr->keylen);
+ memcpy(ctr->V, out + ctr->keylen, 16);
if ((drbg->flags & RAND_DRBG_FLAG_CTR_NO_DF) == 0) {
/* If no input reuse existing derived value */
@@ -262,8 +262,8 @@ __owur static int ctr_update(RAND_DRBG *drbg,
ctr_XOR(ctr, in2, in2len);
}
- if (!EVP_CipherInit_ex(ctr->ctx_ecb, NULL, NULL, ctr->K, NULL, -1)
- || !EVP_CipherInit_ex(ctr->ctx_ctr, NULL, NULL, ctr->K, NULL, -1))
+ if (!EVP_CipherInit_ex(ctr->ctx_ecb, NULL, NULL, ctr->K, NULL, -1)
+ || !EVP_CipherInit_ex(ctr->ctx_ctr, NULL, NULL, ctr->K, NULL, -1))
return 0;
return 1;
}
@@ -280,10 +280,10 @@ __owur static int drbg_ctr_instantiate(RAND_DRBG *drbg,
memset(ctr->K, 0, sizeof(ctr->K));
memset(ctr->V, 0, sizeof(ctr->V));
- if (!EVP_CipherInit_ex(ctr->ctx_ecb, NULL, NULL, ctr->K, NULL, -1))
+ if (!EVP_CipherInit_ex(ctr->ctx_ecb, NULL, NULL, ctr->K, NULL, -1))
return 0;
-
- inc_128(ctr);
+
+ inc_128(ctr);
if (!ctr_update(drbg, entropy, entropylen, pers, perslen, nonce, noncelen))
return 0;
return 1;
@@ -293,40 +293,40 @@ __owur static int drbg_ctr_reseed(RAND_DRBG *drbg,
const unsigned char *entropy, size_t entropylen,
const unsigned char *adin, size_t adinlen)
{
- RAND_DRBG_CTR *ctr = &drbg->data.ctr;
-
+ RAND_DRBG_CTR *ctr = &drbg->data.ctr;
+
if (entropy == NULL)
return 0;
-
- inc_128(ctr);
+
+ inc_128(ctr);
if (!ctr_update(drbg, entropy, entropylen, adin, adinlen, NULL, 0))
return 0;
return 1;
}
-static void ctr96_inc(unsigned char *counter)
-{
- u32 n = 12, c = 1;
-
- do {
- --n;
- c += counter[n];
- counter[n] = (u8)c;
- c >>= 8;
- } while (n);
-}
-
+static void ctr96_inc(unsigned char *counter)
+{
+ u32 n = 12, c = 1;
+
+ do {
+ --n;
+ c += counter[n];
+ counter[n] = (u8)c;
+ c >>= 8;
+ } while (n);
+}
+
__owur static int drbg_ctr_generate(RAND_DRBG *drbg,
unsigned char *out, size_t outlen,
const unsigned char *adin, size_t adinlen)
{
RAND_DRBG_CTR *ctr = &drbg->data.ctr;
- unsigned int ctr32, blocks;
- int outl, buflen;
+ unsigned int ctr32, blocks;
+ int outl, buflen;
if (adin != NULL && adinlen != 0) {
- inc_128(ctr);
-
+ inc_128(ctr);
+
if (!ctr_update(drbg, adin, adinlen, NULL, 0, NULL, 0))
return 0;
/* This means we reuse derived value */
@@ -338,54 +338,54 @@ __owur static int drbg_ctr_generate(RAND_DRBG *drbg,
adinlen = 0;
}
- inc_128(ctr);
+ inc_128(ctr);
- if (outlen == 0) {
+ if (outlen == 0) {
inc_128(ctr);
-
- if (!ctr_update(drbg, adin, adinlen, NULL, 0, NULL, 0))
+
+ if (!ctr_update(drbg, adin, adinlen, NULL, 0, NULL, 0))
return 0;
- return 1;
+ return 1;
}
- memset(out, 0, outlen);
- __msan_unpoison(ctr->V, 16 * sizeof(char));
-
- do {
- if (!EVP_CipherInit_ex(ctr->ctx_ctr,
- NULL, NULL, NULL, ctr->V, -1))
- return 0;
-
- /*-
- * outlen has type size_t while EVP_CipherUpdate takes an
- * int argument and thus cannot be guaranteed to process more
- * than 2^31-1 bytes at a time. We process such huge generate
- * requests in 2^30 byte chunks, which is the greatest multiple
- * of AES block size lower than or equal to 2^31-1.
- */
- buflen = outlen > (1U << 30) ? (1U << 30) : outlen;
- blocks = (buflen + 15) / 16;
-
- ctr32 = GETU32(ctr->V + 12) + blocks;
- if (ctr32 < blocks) {
- /* 32-bit counter overflow into V. */
- if (ctr32 != 0) {
- blocks -= ctr32;
- buflen = blocks * 16;
- ctr32 = 0;
- }
- ctr96_inc(ctr->V);
- }
- PUTU32(ctr->V + 12, ctr32);
-
- if (!EVP_CipherUpdate(ctr->ctx_ctr, out, &outl, out, buflen)
- || outl != buflen)
- return 0;
-
- out += buflen;
- outlen -= buflen;
- } while (outlen);
-
+ memset(out, 0, outlen);
+ __msan_unpoison(ctr->V, 16 * sizeof(char));
+
+ do {
+ if (!EVP_CipherInit_ex(ctr->ctx_ctr,
+ NULL, NULL, NULL, ctr->V, -1))
+ return 0;
+
+ /*-
+ * outlen has type size_t while EVP_CipherUpdate takes an
+ * int argument and thus cannot be guaranteed to process more
+ * than 2^31-1 bytes at a time. We process such huge generate
+ * requests in 2^30 byte chunks, which is the greatest multiple
+ * of AES block size lower than or equal to 2^31-1.
+ */
+ buflen = outlen > (1U << 30) ? (1U << 30) : outlen;
+ blocks = (buflen + 15) / 16;
+
+ ctr32 = GETU32(ctr->V + 12) + blocks;
+ if (ctr32 < blocks) {
+ /* 32-bit counter overflow into V. */
+ if (ctr32 != 0) {
+ blocks -= ctr32;
+ buflen = blocks * 16;
+ ctr32 = 0;
+ }
+ ctr96_inc(ctr->V);
+ }
+ PUTU32(ctr->V + 12, ctr32);
+
+ if (!EVP_CipherUpdate(ctr->ctx_ctr, out, &outl, out, buflen)
+ || outl != buflen)
+ return 0;
+
+ out += buflen;
+ outlen -= buflen;
+ } while (outlen);
+
if (!ctr_update(drbg, adin, adinlen, NULL, 0, NULL, 0))
return 0;
return 1;
@@ -393,8 +393,8 @@ __owur static int drbg_ctr_generate(RAND_DRBG *drbg,
static int drbg_ctr_uninstantiate(RAND_DRBG *drbg)
{
- EVP_CIPHER_CTX_free(drbg->data.ctr.ctx_ecb);
- EVP_CIPHER_CTX_free(drbg->data.ctr.ctx_ctr);
+ EVP_CIPHER_CTX_free(drbg->data.ctr.ctx_ecb);
+ EVP_CIPHER_CTX_free(drbg->data.ctr.ctx_ctr);
EVP_CIPHER_CTX_free(drbg->data.ctr.ctx_df);
OPENSSL_cleanse(&drbg->data.ctr, sizeof(drbg->data.ctr));
return 1;
@@ -418,36 +418,36 @@ int drbg_ctr_init(RAND_DRBG *drbg)
return 0;
case NID_aes_128_ctr:
keylen = 16;
- ctr->cipher_ecb = EVP_aes_128_ecb();
- ctr->cipher_ctr = EVP_aes_128_ctr();
+ ctr->cipher_ecb = EVP_aes_128_ecb();
+ ctr->cipher_ctr = EVP_aes_128_ctr();
break;
case NID_aes_192_ctr:
keylen = 24;
- ctr->cipher_ecb = EVP_aes_192_ecb();
- ctr->cipher_ctr = EVP_aes_192_ctr();
+ ctr->cipher_ecb = EVP_aes_192_ecb();
+ ctr->cipher_ctr = EVP_aes_192_ctr();
break;
case NID_aes_256_ctr:
keylen = 32;
- ctr->cipher_ecb = EVP_aes_256_ecb();
- ctr->cipher_ctr = EVP_aes_256_ctr();
+ ctr->cipher_ecb = EVP_aes_256_ecb();
+ ctr->cipher_ctr = EVP_aes_256_ctr();
break;
}
drbg->meth = &drbg_ctr_meth;
ctr->keylen = keylen;
- if (ctr->ctx_ecb == NULL)
- ctr->ctx_ecb = EVP_CIPHER_CTX_new();
- if (ctr->ctx_ctr == NULL)
- ctr->ctx_ctr = EVP_CIPHER_CTX_new();
- if (ctr->ctx_ecb == NULL || ctr->ctx_ctr == NULL
- || !EVP_CipherInit_ex(ctr->ctx_ecb,
- ctr->cipher_ecb, NULL, NULL, NULL, 1)
- || !EVP_CipherInit_ex(ctr->ctx_ctr,
- ctr->cipher_ctr, NULL, NULL, NULL, 1))
+ if (ctr->ctx_ecb == NULL)
+ ctr->ctx_ecb = EVP_CIPHER_CTX_new();
+ if (ctr->ctx_ctr == NULL)
+ ctr->ctx_ctr = EVP_CIPHER_CTX_new();
+ if (ctr->ctx_ecb == NULL || ctr->ctx_ctr == NULL
+ || !EVP_CipherInit_ex(ctr->ctx_ecb,
+ ctr->cipher_ecb, NULL, NULL, NULL, 1)
+ || !EVP_CipherInit_ex(ctr->ctx_ctr,
+ ctr->cipher_ctr, NULL, NULL, NULL, 1))
return 0;
-
- drbg->meth = &drbg_ctr_meth;
+
+ drbg->meth = &drbg_ctr_meth;
drbg->strength = keylen * 8;
drbg->seedlen = keylen + 16;
@@ -465,8 +465,8 @@ int drbg_ctr_init(RAND_DRBG *drbg)
if (ctr->ctx_df == NULL)
return 0;
/* Set key schedule for df_key */
- if (!EVP_CipherInit_ex(ctr->ctx_df,
- ctr->cipher_ecb, NULL, df_key, NULL, 1))
+ if (!EVP_CipherInit_ex(ctr->ctx_df,
+ ctr->cipher_ecb, NULL, df_key, NULL, 1))
return 0;
drbg->min_entropylen = ctr->keylen;
diff --git a/contrib/libs/openssl/crypto/rand/drbg_lib.c b/contrib/libs/openssl/crypto/rand/drbg_lib.c
index 4faa48b6d5..8c7c28c970 100644
--- a/contrib/libs/openssl/crypto/rand/drbg_lib.c
+++ b/contrib/libs/openssl/crypto/rand/drbg_lib.c
@@ -352,15 +352,15 @@ int RAND_DRBG_instantiate(RAND_DRBG *drbg,
}
drbg->state = DRBG_READY;
- drbg->generate_counter = 1;
+ drbg->generate_counter = 1;
drbg->reseed_time = time(NULL);
- if (drbg->enable_reseed_propagation) {
- if (drbg->parent == NULL)
- tsan_counter(&drbg->reseed_counter);
- else
- tsan_store(&drbg->reseed_counter,
- tsan_load(&drbg->parent->reseed_counter));
- }
+ if (drbg->enable_reseed_propagation) {
+ if (drbg->parent == NULL)
+ tsan_counter(&drbg->reseed_counter);
+ else
+ tsan_store(&drbg->reseed_counter,
+ tsan_load(&drbg->parent->reseed_counter));
+ }
end:
if (entropy != NULL && drbg->cleanup_entropy != NULL)
@@ -442,15 +442,15 @@ int RAND_DRBG_reseed(RAND_DRBG *drbg,
goto end;
drbg->state = DRBG_READY;
- drbg->generate_counter = 1;
+ drbg->generate_counter = 1;
drbg->reseed_time = time(NULL);
- if (drbg->enable_reseed_propagation) {
- if (drbg->parent == NULL)
- tsan_counter(&drbg->reseed_counter);
- else
- tsan_store(&drbg->reseed_counter,
- tsan_load(&drbg->parent->reseed_counter));
- }
+ if (drbg->enable_reseed_propagation) {
+ if (drbg->parent == NULL)
+ tsan_counter(&drbg->reseed_counter);
+ else
+ tsan_store(&drbg->reseed_counter,
+ tsan_load(&drbg->parent->reseed_counter));
+ }
end:
if (entropy != NULL && drbg->cleanup_entropy != NULL)
@@ -551,9 +551,9 @@ int rand_drbg_restart(RAND_DRBG *drbg,
drbg->meth->reseed(drbg, adin, adinlen, NULL, 0);
} else if (reseeded == 0) {
/* do a full reseeding if it has not been done yet above */
- if (!RAND_DRBG_reseed(drbg, NULL, 0, 0)) {
- RANDerr(RAND_F_RAND_DRBG_RESTART, RAND_R_RESEED_ERROR);
- }
+ if (!RAND_DRBG_reseed(drbg, NULL, 0, 0)) {
+ RANDerr(RAND_F_RAND_DRBG_RESTART, RAND_R_RESEED_ERROR);
+ }
}
}
@@ -611,7 +611,7 @@ int RAND_DRBG_generate(RAND_DRBG *drbg, unsigned char *out, size_t outlen,
}
if (drbg->reseed_interval > 0) {
- if (drbg->generate_counter >= drbg->reseed_interval)
+ if (drbg->generate_counter >= drbg->reseed_interval)
reseed_required = 1;
}
if (drbg->reseed_time_interval > 0) {
@@ -620,8 +620,8 @@ int RAND_DRBG_generate(RAND_DRBG *drbg, unsigned char *out, size_t outlen,
|| now - drbg->reseed_time >= drbg->reseed_time_interval)
reseed_required = 1;
}
- if (drbg->enable_reseed_propagation && drbg->parent != NULL) {
- if (drbg->reseed_counter != tsan_load(&drbg->parent->reseed_counter))
+ if (drbg->enable_reseed_propagation && drbg->parent != NULL) {
+ if (drbg->reseed_counter != tsan_load(&drbg->parent->reseed_counter))
reseed_required = 1;
}
@@ -640,7 +640,7 @@ int RAND_DRBG_generate(RAND_DRBG *drbg, unsigned char *out, size_t outlen,
return 0;
}
- drbg->generate_counter++;
+ drbg->generate_counter++;
return 1;
}
@@ -702,7 +702,7 @@ int RAND_DRBG_set_callbacks(RAND_DRBG *drbg,
RAND_DRBG_get_nonce_fn get_nonce,
RAND_DRBG_cleanup_nonce_fn cleanup_nonce)
{
- if (drbg->state != DRBG_UNINITIALISED)
+ if (drbg->state != DRBG_UNINITIALISED)
return 0;
drbg->get_entropy = get_entropy;
drbg->cleanup_entropy = cleanup_entropy;
@@ -878,9 +878,9 @@ static RAND_DRBG *drbg_setup(RAND_DRBG *parent)
if (parent == NULL && rand_drbg_enable_locking(drbg) == 0)
goto err;
- /* enable reseed propagation */
- drbg->enable_reseed_propagation = 1;
- drbg->reseed_counter = 1;
+ /* enable reseed propagation */
+ drbg->enable_reseed_propagation = 1;
+ drbg->reseed_counter = 1;
/*
* Ignore instantiation error to support just-in-time instantiation.
diff --git a/contrib/libs/openssl/crypto/rand/rand_lib.c b/contrib/libs/openssl/crypto/rand/rand_lib.c
index bf0b661efc..5c72fad8ca 100644
--- a/contrib/libs/openssl/crypto/rand/rand_lib.c
+++ b/contrib/libs/openssl/crypto/rand/rand_lib.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -432,13 +432,13 @@ err:
RAND_POOL *rand_pool_new(int entropy_requested, int secure,
size_t min_len, size_t max_len)
{
- RAND_POOL *pool;
+ RAND_POOL *pool;
size_t min_alloc_size = RAND_POOL_MIN_ALLOCATION(secure);
- if (!RUN_ONCE(&rand_init, do_rand_init))
- return NULL;
-
- pool = OPENSSL_zalloc(sizeof(*pool));
+ if (!RUN_ONCE(&rand_init, do_rand_init))
+ return NULL;
+
+ pool = OPENSSL_zalloc(sizeof(*pool));
if (pool == NULL) {
RANDerr(RAND_F_RAND_POOL_NEW, ERR_R_MALLOC_FAILURE);
return NULL;
diff --git a/contrib/libs/openssl/crypto/rand/rand_local.h b/contrib/libs/openssl/crypto/rand/rand_local.h
index 2e7dcd0778..a5de5252dc 100644
--- a/contrib/libs/openssl/crypto/rand/rand_local.h
+++ b/contrib/libs/openssl/crypto/rand/rand_local.h
@@ -138,11 +138,11 @@ typedef struct rand_drbg_method_st {
* The state of a DRBG AES-CTR.
*/
typedef struct rand_drbg_ctr_st {
- EVP_CIPHER_CTX *ctx_ecb;
- EVP_CIPHER_CTX *ctx_ctr;
+ EVP_CIPHER_CTX *ctx_ecb;
+ EVP_CIPHER_CTX *ctx_ctr;
EVP_CIPHER_CTX *ctx_df;
- const EVP_CIPHER *cipher_ecb;
- const EVP_CIPHER *cipher_ctr;
+ const EVP_CIPHER *cipher_ecb;
+ const EVP_CIPHER *cipher_ctr;
size_t keylen;
unsigned char K[32];
unsigned char V[16];
@@ -235,7 +235,7 @@ struct rand_drbg_st {
size_t max_perslen, max_adinlen;
/* Counts the number of generate requests since the last reseed. */
- unsigned int generate_counter;
+ unsigned int generate_counter;
/*
* Maximum number of generate requests until a reseed is required.
* This value is ignored if it is zero.
@@ -248,15 +248,15 @@ struct rand_drbg_st {
* This value is ignored if it is zero.
*/
time_t reseed_time_interval;
-
+
+ /*
+ * Enables reseed propagation (see following comment)
+ */
+ unsigned int enable_reseed_propagation;
+
/*
- * Enables reseed propagation (see following comment)
- */
- unsigned int enable_reseed_propagation;
-
- /*
* Counts the number of reseeds since instantiation.
- * This value is ignored if enable_reseed_propagation is zero.
+ * This value is ignored if enable_reseed_propagation is zero.
*
* This counter is used only for seed propagation from the <master> DRBG
* to its two children, the <public> and <private> DRBG. This feature is
@@ -264,7 +264,7 @@ struct rand_drbg_st {
* is added by RAND_add() or RAND_seed() will have an immediate effect on
* the output of RAND_bytes() resp. RAND_priv_bytes().
*/
- TSAN_QUALIFIER unsigned int reseed_counter;
+ TSAN_QUALIFIER unsigned int reseed_counter;
size_t seedlen;
DRBG_STATUS state;
diff --git a/contrib/libs/openssl/crypto/rand/rand_unix.c b/contrib/libs/openssl/crypto/rand/rand_unix.c
index 184095115b..5766e5abe7 100644
--- a/contrib/libs/openssl/crypto/rand/rand_unix.c
+++ b/contrib/libs/openssl/crypto/rand/rand_unix.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -26,17 +26,17 @@
# include <sys/utsname.h>
# endif
#endif
-#if (defined(__FreeBSD__) || defined(__NetBSD__)) && !defined(OPENSSL_SYS_UEFI)
+#if (defined(__FreeBSD__) || defined(__NetBSD__)) && !defined(OPENSSL_SYS_UEFI)
# include <sys/types.h>
# include <sys/sysctl.h>
# include <sys/param.h>
#endif
-#if defined(__OpenBSD__)
+#if defined(__OpenBSD__)
# include <sys/param.h>
#endif
-#if defined(__APPLE__)
-# include <CommonCrypto/CommonRandom.h> // Y_IGNORE
-#endif
+#if defined(__APPLE__)
+# include <CommonCrypto/CommonRandom.h> // Y_IGNORE
+#endif
#if defined(OPENSSL_SYS_UNIX) || defined(__DJGPP__)
# include <sys/types.h>
@@ -250,12 +250,12 @@ static ssize_t sysctl_random(char *buf, size_t buflen)
* when the sysctl returns long and we want to request something not a
* multiple of longs, which should never be the case.
*/
-#if defined(__FreeBSD__)
+#if defined(__FreeBSD__)
if (!ossl_assert(buflen % sizeof(long) == 0)) {
errno = EINVAL;
return -1;
}
-#endif
+#endif
/*
* On NetBSD before 4.0 KERN_ARND was an alias for KERN_URND, and only
@@ -273,7 +273,7 @@ static ssize_t sysctl_random(char *buf, size_t buflen)
mib[1] = KERN_ARND;
do {
- len = buflen > 256 ? 256 : buflen;
+ len = buflen > 256 ? 256 : buflen;
if (sysctl(mib, 2, buf, &len, NULL, 0) == -1)
return done > 0 ? done : -1;
done += len;
@@ -368,24 +368,24 @@ static ssize_t syscall_random(void *buf, size_t buflen)
* - OpenBSD since 5.6
* - Linux since 3.17 with glibc 2.25
* - FreeBSD since 12.0 (1200061)
- *
- * Note: Sometimes getentropy() can be provided but not implemented
- * internally. So we need to check errno for ENOSYS
+ *
+ * Note: Sometimes getentropy() can be provided but not implemented
+ * internally. So we need to check errno for ENOSYS
*/
# if defined(__GNUC__) && __GNUC__>=2 && defined(__ELF__) && !defined(__hpux)
extern int getentropy(void *buffer, size_t length) __attribute__((weak));
- if (getentropy != NULL) {
- if (getentropy(buf, buflen) == 0)
- return (ssize_t)buflen;
- if (errno != ENOSYS)
- return -1;
- }
-# elif defined(__APPLE__)
- if (CCRandomGenerateBytes(buf, buflen) == kCCSuccess)
- return (ssize_t)buflen;
-
- return -1;
+ if (getentropy != NULL) {
+ if (getentropy(buf, buflen) == 0)
+ return (ssize_t)buflen;
+ if (errno != ENOSYS)
+ return -1;
+ }
+# elif defined(__APPLE__)
+ if (CCRandomGenerateBytes(buf, buflen) == kCCSuccess)
+ return (ssize_t)buflen;
+
+ return -1;
# else
union {
void *p;
@@ -426,8 +426,8 @@ static struct random_device {
} random_devices[OSSL_NELEM(random_device_paths)];
static int keep_random_devices_open = 1;
-# if defined(__linux) && defined(DEVRANDOM_WAIT) \
- && defined(OPENSSL_RAND_SEED_GETRANDOM)
+# if defined(__linux) && defined(DEVRANDOM_WAIT) \
+ && defined(OPENSSL_RAND_SEED_GETRANDOM)
static void *shm_addr;
static void cleanup_shm(void)
@@ -505,7 +505,7 @@ static int wait_random_seeded(void)
}
return seeded;
}
-# else /* defined __linux && DEVRANDOM_WAIT && OPENSSL_RAND_SEED_GETRANDOM */
+# else /* defined __linux && DEVRANDOM_WAIT && OPENSSL_RAND_SEED_GETRANDOM */
static int wait_random_seeded(void)
{
return 1;
diff --git a/contrib/libs/openssl/crypto/rand/randfile.c b/contrib/libs/openssl/crypto/rand/randfile.c
index 957a68ccfc..229ce864a3 100644
--- a/contrib/libs/openssl/crypto/rand/randfile.c
+++ b/contrib/libs/openssl/crypto/rand/randfile.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -26,7 +26,7 @@
#ifndef OPENSSL_NO_POSIX_IO
# include <sys/stat.h>
# include <fcntl.h>
-# if defined(_WIN32) && !defined(_WIN32_WCE)
+# if defined(_WIN32) && !defined(_WIN32_WCE)
# include <windows.h>
# include <io.h>
# define stat _stat
diff --git a/contrib/libs/openssl/crypto/rsa/rsa_ameth.c b/contrib/libs/openssl/crypto/rsa/rsa_ameth.c
index 5a7d5e8447..fb045544a8 100644
--- a/contrib/libs/openssl/crypto/rsa/rsa_ameth.c
+++ b/contrib/libs/openssl/crypto/rsa/rsa_ameth.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2006-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2006-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -118,15 +118,15 @@ static int rsa_pub_decode(EVP_PKEY *pkey, X509_PUBKEY *pubkey)
static int rsa_pub_cmp(const EVP_PKEY *a, const EVP_PKEY *b)
{
- /*
- * Don't check the public/private key, this is mostly for smart
- * cards.
- */
- if (((RSA_flags(a->pkey.rsa) & RSA_METHOD_FLAG_NO_CHECK))
- || (RSA_flags(b->pkey.rsa) & RSA_METHOD_FLAG_NO_CHECK)) {
- return 1;
- }
-
+ /*
+ * Don't check the public/private key, this is mostly for smart
+ * cards.
+ */
+ if (((RSA_flags(a->pkey.rsa) & RSA_METHOD_FLAG_NO_CHECK))
+ || (RSA_flags(b->pkey.rsa) & RSA_METHOD_FLAG_NO_CHECK)) {
+ return 1;
+ }
+
if (BN_cmp(b->pkey.rsa->n, a->pkey.rsa->n) != 0
|| BN_cmp(b->pkey.rsa->e, a->pkey.rsa->e) != 0)
return 0;
diff --git a/contrib/libs/openssl/crypto/rsa/rsa_prn.c b/contrib/libs/openssl/crypto/rsa/rsa_prn.c
index 11f4e1f592..23df448a52 100644
--- a/contrib/libs/openssl/crypto/rsa/rsa_prn.c
+++ b/contrib/libs/openssl/crypto/rsa/rsa_prn.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2006-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2006-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -34,11 +34,11 @@ int RSA_print(BIO *bp, const RSA *x, int off)
EVP_PKEY *pk;
int ret;
pk = EVP_PKEY_new();
- if (pk == NULL)
+ if (pk == NULL)
return 0;
- ret = EVP_PKEY_set1_RSA(pk, (RSA *)x);
- if (ret)
- ret = EVP_PKEY_print_private(bp, pk, off, NULL);
+ ret = EVP_PKEY_set1_RSA(pk, (RSA *)x);
+ if (ret)
+ ret = EVP_PKEY_print_private(bp, pk, off, NULL);
EVP_PKEY_free(pk);
return ret;
}
diff --git a/contrib/libs/openssl/crypto/rsa/rsa_ssl.c b/contrib/libs/openssl/crypto/rsa/rsa_ssl.c
index 6df25b2479..e1c755ae46 100644
--- a/contrib/libs/openssl/crypto/rsa/rsa_ssl.c
+++ b/contrib/libs/openssl/crypto/rsa/rsa_ssl.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -55,7 +55,7 @@ int RSA_padding_add_SSLv23(unsigned char *to, int tlen,
/*
* Copy of RSA_padding_check_PKCS1_type_2 with a twist that rejects padding
- * if nul delimiter is preceded by 8 consecutive 0x03 bytes. It also
+ * if nul delimiter is preceded by 8 consecutive 0x03 bytes. It also
* preserves error code reporting for backward compatibility.
*/
int RSA_padding_check_SSLv23(unsigned char *to, int tlen,
@@ -122,13 +122,13 @@ int RSA_padding_check_SSLv23(unsigned char *to, int tlen,
RSA_R_NULL_BEFORE_BLOCK_MISSING);
mask = ~good;
- /*
- * Reject if nul delimiter is preceded by 8 consecutive 0x03 bytes. Note
- * that RFC5246 incorrectly states this the other way around, i.e. reject
- * if it is not preceded by 8 consecutive 0x03 bytes. However this is
- * corrected in subsequent errata for that RFC.
- */
- good &= constant_time_lt(threes_in_row, 8);
+ /*
+ * Reject if nul delimiter is preceded by 8 consecutive 0x03 bytes. Note
+ * that RFC5246 incorrectly states this the other way around, i.e. reject
+ * if it is not preceded by 8 consecutive 0x03 bytes. However this is
+ * corrected in subsequent errata for that RFC.
+ */
+ good &= constant_time_lt(threes_in_row, 8);
err = constant_time_select_int(mask | good, err,
RSA_R_SSLV3_ROLLBACK_ATTACK);
mask = ~good;
diff --git a/contrib/libs/openssl/crypto/siphash/siphash_ameth.c b/contrib/libs/openssl/crypto/siphash/siphash_ameth.c
index 4dbfd1c2c5..7fce76390e 100644
--- a/contrib/libs/openssl/crypto/siphash/siphash_ameth.c
+++ b/contrib/libs/openssl/crypto/siphash/siphash_ameth.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2007-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2007-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -44,7 +44,7 @@ static int siphash_pkey_ctrl(EVP_PKEY *pkey, int op, long arg1, void *arg2)
static int siphash_pkey_public_cmp(const EVP_PKEY *a, const EVP_PKEY *b)
{
- return ASN1_OCTET_STRING_cmp(EVP_PKEY_get0(a), EVP_PKEY_get0(b)) == 0;
+ return ASN1_OCTET_STRING_cmp(EVP_PKEY_get0(a), EVP_PKEY_get0(b)) == 0;
}
static int siphash_set_priv_key(EVP_PKEY *pkey, const unsigned char *priv,
diff --git a/contrib/libs/openssl/crypto/sm2/sm2_crypt.c b/contrib/libs/openssl/crypto/sm2/sm2_crypt.c
index 4df7a64639..83b97f4edc 100644
--- a/contrib/libs/openssl/crypto/sm2/sm2_crypt.c
+++ b/contrib/libs/openssl/crypto/sm2/sm2_crypt.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2017-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2017-2021 The OpenSSL Project Authors. All Rights Reserved.
* Copyright 2017 Ribose Inc. All Rights Reserved.
* Ported from Ribose contributions from Botan.
*
@@ -61,20 +61,20 @@ static size_t ec_field_size(const EC_GROUP *group)
return field_size;
}
-int sm2_plaintext_size(const unsigned char *ct, size_t ct_size, size_t *pt_size)
+int sm2_plaintext_size(const unsigned char *ct, size_t ct_size, size_t *pt_size)
{
- struct SM2_Ciphertext_st *sm2_ctext = NULL;
+ struct SM2_Ciphertext_st *sm2_ctext = NULL;
- sm2_ctext = d2i_SM2_Ciphertext(NULL, &ct, ct_size);
+ sm2_ctext = d2i_SM2_Ciphertext(NULL, &ct, ct_size);
- if (sm2_ctext == NULL) {
+ if (sm2_ctext == NULL) {
SM2err(SM2_F_SM2_PLAINTEXT_SIZE, SM2_R_INVALID_ENCODING);
return 0;
}
- *pt_size = sm2_ctext->C2->length;
- SM2_Ciphertext_free(sm2_ctext);
-
+ *pt_size = sm2_ctext->C2->length;
+ SM2_Ciphertext_free(sm2_ctext);
+
return 1;
}
@@ -294,10 +294,10 @@ int sm2_decrypt(const EC_KEY *key,
C2 = sm2_ctext->C2->data;
C3 = sm2_ctext->C3->data;
msg_len = sm2_ctext->C2->length;
- if (*ptext_len < (size_t)msg_len) {
- SM2err(SM2_F_SM2_DECRYPT, SM2_R_BUFFER_TOO_SMALL);
- goto done;
- }
+ if (*ptext_len < (size_t)msg_len) {
+ SM2err(SM2_F_SM2_DECRYPT, SM2_R_BUFFER_TOO_SMALL);
+ goto done;
+ }
ctx = BN_CTX_new();
if (ctx == NULL) {
diff --git a/contrib/libs/openssl/crypto/sm2/sm2_pmeth.c b/contrib/libs/openssl/crypto/sm2/sm2_pmeth.c
index 6f85dd1d9f..0e722b910b 100644
--- a/contrib/libs/openssl/crypto/sm2/sm2_pmeth.c
+++ b/contrib/libs/openssl/crypto/sm2/sm2_pmeth.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2006-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2006-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -151,7 +151,7 @@ static int pkey_sm2_decrypt(EVP_PKEY_CTX *ctx,
const EVP_MD *md = (dctx->md == NULL) ? EVP_sm3() : dctx->md;
if (out == NULL) {
- if (!sm2_plaintext_size(in, inlen, outlen))
+ if (!sm2_plaintext_size(in, inlen, outlen))
return -1;
else
return 1;
diff --git a/contrib/libs/openssl/crypto/sparcv9cap.c b/contrib/libs/openssl/crypto/sparcv9cap.c
index 75ca9e3da8..b3cb3d4be9 100644
--- a/contrib/libs/openssl/crypto/sparcv9cap.c
+++ b/contrib/libs/openssl/crypto/sparcv9cap.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2005-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2005-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -16,7 +16,7 @@
#include <unistd.h>
#include <openssl/bn.h>
#include "internal/cryptlib.h"
-#include "bn/bn_local.h" /* for definition of bn_mul_mont */
+#include "bn/bn_local.h" /* for definition of bn_mul_mont */
#include "sparc_arch.h"
diff --git a/contrib/libs/openssl/crypto/srp/srp_lib.c b/contrib/libs/openssl/crypto/srp/srp_lib.c
index 6215766523..ce3504825c 100644
--- a/contrib/libs/openssl/crypto/srp/srp_lib.c
+++ b/contrib/libs/openssl/crypto/srp/srp_lib.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2004-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2004-2021 The OpenSSL Project Authors. All Rights Reserved.
* Copyright (c) 2004, EdelKey Project. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
@@ -177,7 +177,7 @@ BIGNUM *SRP_Calc_client_key(const BIGNUM *N, const BIGNUM *B, const BIGNUM *g,
const BIGNUM *x, const BIGNUM *a, const BIGNUM *u)
{
BIGNUM *tmp = NULL, *tmp2 = NULL, *tmp3 = NULL, *k = NULL, *K = NULL;
- BIGNUM *xtmp = NULL;
+ BIGNUM *xtmp = NULL;
BN_CTX *bn_ctx;
if (u == NULL || B == NULL || N == NULL || g == NULL || x == NULL
@@ -186,13 +186,13 @@ BIGNUM *SRP_Calc_client_key(const BIGNUM *N, const BIGNUM *B, const BIGNUM *g,
if ((tmp = BN_new()) == NULL ||
(tmp2 = BN_new()) == NULL ||
- (tmp3 = BN_new()) == NULL ||
- (xtmp = BN_new()) == NULL)
+ (tmp3 = BN_new()) == NULL ||
+ (xtmp = BN_new()) == NULL)
goto err;
- BN_with_flags(xtmp, x, BN_FLG_CONSTTIME);
- BN_set_flags(tmp, BN_FLG_CONSTTIME);
- if (!BN_mod_exp(tmp, g, xtmp, N, bn_ctx))
+ BN_with_flags(xtmp, x, BN_FLG_CONSTTIME);
+ BN_set_flags(tmp, BN_FLG_CONSTTIME);
+ if (!BN_mod_exp(tmp, g, xtmp, N, bn_ctx))
goto err;
if ((k = srp_Calc_k(N, g)) == NULL)
goto err;
@@ -200,7 +200,7 @@ BIGNUM *SRP_Calc_client_key(const BIGNUM *N, const BIGNUM *B, const BIGNUM *g,
goto err;
if (!BN_mod_sub(tmp, B, tmp2, N, bn_ctx))
goto err;
- if (!BN_mul(tmp3, u, xtmp, bn_ctx))
+ if (!BN_mul(tmp3, u, xtmp, bn_ctx))
goto err;
if (!BN_add(tmp2, a, tmp3))
goto err;
@@ -212,7 +212,7 @@ BIGNUM *SRP_Calc_client_key(const BIGNUM *N, const BIGNUM *B, const BIGNUM *g,
err:
BN_CTX_free(bn_ctx);
- BN_free(xtmp);
+ BN_free(xtmp);
BN_clear_free(tmp);
BN_clear_free(tmp2);
BN_clear_free(tmp3);
diff --git a/contrib/libs/openssl/crypto/srp/srp_vfy.c b/contrib/libs/openssl/crypto/srp/srp_vfy.c
index f8628edbd6..394e1180df 100644
--- a/contrib/libs/openssl/crypto/srp/srp_vfy.c
+++ b/contrib/libs/openssl/crypto/srp/srp_vfy.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2004-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2004-2021 The OpenSSL Project Authors. All Rights Reserved.
* Copyright (c) 2004, EdelKey Project. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
@@ -684,7 +684,7 @@ int SRP_create_verifier_BN(const char *user, const char *pass, BIGNUM **salt,
BIGNUM *x = NULL;
BN_CTX *bn_ctx = BN_CTX_new();
unsigned char tmp2[MAX_LEN];
- BIGNUM *salttmp = NULL, *verif;
+ BIGNUM *salttmp = NULL, *verif;
if ((user == NULL) ||
(pass == NULL) ||
@@ -707,18 +707,18 @@ int SRP_create_verifier_BN(const char *user, const char *pass, BIGNUM **salt,
if (x == NULL)
goto err;
- verif = BN_new();
- if (verif == NULL)
+ verif = BN_new();
+ if (verif == NULL)
goto err;
- if (!BN_mod_exp(verif, g, x, N, bn_ctx)) {
- BN_clear_free(verif);
+ if (!BN_mod_exp(verif, g, x, N, bn_ctx)) {
+ BN_clear_free(verif);
goto err;
}
result = 1;
*salt = salttmp;
- *verifier = verif;
+ *verifier = verif;
err:
if (salt != NULL && *salt != salttmp)
diff --git a/contrib/libs/openssl/crypto/store/loader_file.c b/contrib/libs/openssl/crypto/store/loader_file.c
index b5b5098708..32e7b9f65a 100644
--- a/contrib/libs/openssl/crypto/store/loader_file.c
+++ b/contrib/libs/openssl/crypto/store/loader_file.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2016-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2016-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -370,7 +370,7 @@ static OSSL_STORE_INFO *try_decode_PKCS8Encrypted(const char *pem_name,
mem->data = (char *)new_data;
mem->max = mem->length = (size_t)new_data_len;
X509_SIG_free(p8);
- p8 = NULL;
+ p8 = NULL;
store_info = ossl_store_info_new_EMBEDDED(PEM_STRING_PKCS8INF, mem);
if (store_info == NULL) {
@@ -430,43 +430,43 @@ static OSSL_STORE_INFO *try_decode_PrivateKey(const char *pem_name,
}
} else {
int i;
-#ifndef OPENSSL_NO_ENGINE
- ENGINE *curengine = ENGINE_get_first();
-
- while (curengine != NULL) {
- ENGINE_PKEY_ASN1_METHS_PTR asn1meths =
- ENGINE_get_pkey_asn1_meths(curengine);
-
- if (asn1meths != NULL) {
- const int *nids = NULL;
- int nids_n = asn1meths(curengine, NULL, &nids, 0);
-
- for (i = 0; i < nids_n; i++) {
- EVP_PKEY_ASN1_METHOD *ameth2 = NULL;
- EVP_PKEY *tmp_pkey = NULL;
- const unsigned char *tmp_blob = blob;
-
- if (!asn1meths(curengine, &ameth2, NULL, nids[i]))
- continue;
- if (ameth2 == NULL
- || ameth2->pkey_flags & ASN1_PKEY_ALIAS)
- continue;
-
- tmp_pkey = d2i_PrivateKey(ameth2->pkey_id, NULL,
- &tmp_blob, len);
- if (tmp_pkey != NULL) {
- if (pkey != NULL)
- EVP_PKEY_free(tmp_pkey);
- else
- pkey = tmp_pkey;
- (*matchcount)++;
- }
- }
- }
- curengine = ENGINE_get_next(curengine);
- }
-#endif
-
+#ifndef OPENSSL_NO_ENGINE
+ ENGINE *curengine = ENGINE_get_first();
+
+ while (curengine != NULL) {
+ ENGINE_PKEY_ASN1_METHS_PTR asn1meths =
+ ENGINE_get_pkey_asn1_meths(curengine);
+
+ if (asn1meths != NULL) {
+ const int *nids = NULL;
+ int nids_n = asn1meths(curengine, NULL, &nids, 0);
+
+ for (i = 0; i < nids_n; i++) {
+ EVP_PKEY_ASN1_METHOD *ameth2 = NULL;
+ EVP_PKEY *tmp_pkey = NULL;
+ const unsigned char *tmp_blob = blob;
+
+ if (!asn1meths(curengine, &ameth2, NULL, nids[i]))
+ continue;
+ if (ameth2 == NULL
+ || ameth2->pkey_flags & ASN1_PKEY_ALIAS)
+ continue;
+
+ tmp_pkey = d2i_PrivateKey(ameth2->pkey_id, NULL,
+ &tmp_blob, len);
+ if (tmp_pkey != NULL) {
+ if (pkey != NULL)
+ EVP_PKEY_free(tmp_pkey);
+ else
+ pkey = tmp_pkey;
+ (*matchcount)++;
+ }
+ }
+ }
+ curengine = ENGINE_get_next(curengine);
+ }
+#endif
+
for (i = 0; i < EVP_PKEY_asn1_get_count(); i++) {
EVP_PKEY *tmp_pkey = NULL;
const unsigned char *tmp_blob = blob;
diff --git a/contrib/libs/openssl/crypto/store/store_lib.c b/contrib/libs/openssl/crypto/store/store_lib.c
index 447fa98b3b..fb71f84725 100644
--- a/contrib/libs/openssl/crypto/store/store_lib.c
+++ b/contrib/libs/openssl/crypto/store/store_lib.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2016-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2016-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -218,12 +218,12 @@ int OSSL_STORE_eof(OSSL_STORE_CTX *ctx)
int OSSL_STORE_close(OSSL_STORE_CTX *ctx)
{
- int loader_ret;
+ int loader_ret;
+
+ if (ctx == NULL)
+ return 1;
+ loader_ret = ctx->loader->close(ctx->loader_ctx);
- if (ctx == NULL)
- return 1;
- loader_ret = ctx->loader->close(ctx->loader_ctx);
-
OPENSSL_free(ctx);
return loader_ret;
}
diff --git a/contrib/libs/openssl/crypto/ts/ts_rsp_sign.c b/contrib/libs/openssl/crypto/ts/ts_rsp_sign.c
index dd8de9666a..342582f024 100644
--- a/contrib/libs/openssl/crypto/ts/ts_rsp_sign.c
+++ b/contrib/libs/openssl/crypto/ts/ts_rsp_sign.c
@@ -57,14 +57,14 @@ static ASN1_INTEGER *def_serial_cb(struct TS_resp_ctx *ctx, void *data)
goto err;
if (!ASN1_INTEGER_set(serial, 1))
goto err;
-
+
return serial;
err:
TSerr(TS_F_DEF_SERIAL_CB, ERR_R_MALLOC_FAILURE);
TS_RESP_CTX_set_status_info(ctx, TS_STATUS_REJECTION,
"Error during serial number generation.");
- ASN1_INTEGER_free(serial);
+ ASN1_INTEGER_free(serial);
return NULL;
}
diff --git a/contrib/libs/openssl/crypto/ts/ts_rsp_verify.c b/contrib/libs/openssl/crypto/ts/ts_rsp_verify.c
index 6eae115cae..7fe3d27e74 100644
--- a/contrib/libs/openssl/crypto/ts/ts_rsp_verify.c
+++ b/contrib/libs/openssl/crypto/ts/ts_rsp_verify.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2006-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2006-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -612,7 +612,7 @@ static int ts_compute_imprint(BIO *data, TS_TST_INFO *tst_info,
err:
EVP_MD_CTX_free(md_ctx);
X509_ALGOR_free(*md_alg);
- *md_alg = NULL;
+ *md_alg = NULL;
OPENSSL_free(*imprint);
*imprint_len = 0;
*imprint = 0;
diff --git a/contrib/libs/openssl/crypto/ts/ts_verify_ctx.c b/contrib/libs/openssl/crypto/ts/ts_verify_ctx.c
index 5a0e6fda77..32cd2f542b 100644
--- a/contrib/libs/openssl/crypto/ts/ts_verify_ctx.c
+++ b/contrib/libs/openssl/crypto/ts/ts_verify_ctx.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2006-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2006-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -126,8 +126,8 @@ TS_VERIFY_CTX *TS_REQ_to_TS_VERIFY_CTX(TS_REQ *req, TS_VERIFY_CTX *ctx)
goto err;
msg = imprint->hashed_msg;
ret->imprint_len = ASN1_STRING_length(msg);
- if (ret->imprint_len <= 0)
- goto err;
+ if (ret->imprint_len <= 0)
+ goto err;
if ((ret->imprint = OPENSSL_malloc(ret->imprint_len)) == NULL)
goto err;
memcpy(ret->imprint, ASN1_STRING_get0_data(msg), ret->imprint_len);
diff --git a/contrib/libs/openssl/crypto/ui/ui_openssl.c b/contrib/libs/openssl/crypto/ui/ui_openssl.c
index 874de2f5d0..9526c16536 100644
--- a/contrib/libs/openssl/crypto/ui/ui_openssl.c
+++ b/contrib/libs/openssl/crypto/ui/ui_openssl.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2001-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2001-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -439,16 +439,16 @@ static int open_console(UI *ui)
is_a_tty = 0;
else
# endif
-# ifdef EPERM
- /*
- * Linux can return EPERM (Operation not permitted),
- * e.g. if a daemon executes openssl via fork()+execve()
- * This should be ok
- */
- if (errno == EPERM)
- is_a_tty = 0;
- else
-# endif
+# ifdef EPERM
+ /*
+ * Linux can return EPERM (Operation not permitted),
+ * e.g. if a daemon executes openssl via fork()+execve()
+ * This should be ok
+ */
+ if (errno == EPERM)
+ is_a_tty = 0;
+ else
+# endif
# ifdef ENODEV
/*
* MacOS X returns ENODEV (Operation not supported by device),
diff --git a/contrib/libs/openssl/crypto/uid.c b/contrib/libs/openssl/crypto/uid.c
index c5968036e3..5e3315eeb2 100644
--- a/contrib/libs/openssl/crypto/uid.c
+++ b/contrib/libs/openssl/crypto/uid.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2001-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2001-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -36,12 +36,12 @@ int OPENSSL_issetugid(void)
# include <sys/auxv.h>
# define OSSL_IMPLEMENT_GETAUXVAL
# endif
-# elif defined(__ANDROID_API__)
-/* see https://developer.android.google.cn/ndk/guides/cpu-features */
-# if __ANDROID_API__ >= 18
-# include <sys/auxv.h>
-# define OSSL_IMPLEMENT_GETAUXVAL
-# endif
+# elif defined(__ANDROID_API__)
+/* see https://developer.android.google.cn/ndk/guides/cpu-features */
+# if __ANDROID_API__ >= 18
+# include <sys/auxv.h>
+# define OSSL_IMPLEMENT_GETAUXVAL
+# endif
# endif
int OPENSSL_issetugid(void)
diff --git a/contrib/libs/openssl/crypto/whrlpool/wp_block.c b/contrib/libs/openssl/crypto/whrlpool/wp_block.c
index 10bf9b3c80..39ad009c01 100644
--- a/contrib/libs/openssl/crypto/whrlpool/wp_block.c
+++ b/contrib/libs/openssl/crypto/whrlpool/wp_block.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2005-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2005-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -63,20 +63,20 @@ typedef unsigned long long u64;
# undef STRICT_ALIGNMENT
#endif
-#ifndef STRICT_ALIGNMENT
-# ifdef __GNUC__
-typedef u64 u64_a1 __attribute((__aligned__(1)));
-# else
-typedef u64 u64_a1;
-# endif
-#endif
-
-#if defined(__GNUC__) && !defined(STRICT_ALIGNMENT)
-typedef u64 u64_aX __attribute((__aligned__(1)));
-#else
-typedef u64 u64_aX;
-#endif
-
+#ifndef STRICT_ALIGNMENT
+# ifdef __GNUC__
+typedef u64 u64_a1 __attribute((__aligned__(1)));
+# else
+typedef u64 u64_a1;
+# endif
+#endif
+
+#if defined(__GNUC__) && !defined(STRICT_ALIGNMENT)
+typedef u64 u64_aX __attribute((__aligned__(1)));
+#else
+typedef u64 u64_aX;
+#endif
+
#undef SMALL_REGISTER_BANK
#if defined(__i386) || defined(__i386__) || defined(_M_IX86)
# define SMALL_REGISTER_BANK
@@ -205,13 +205,13 @@ typedef u64 u64_aX;
# define LL(c0,c1,c2,c3,c4,c5,c6,c7) c0,c1,c2,c3,c4,c5,c6,c7, \
c0,c1,c2,c3,c4,c5,c6,c7
# define C0(K,i) (((u64*)(Cx.c+0))[2*K.c[(i)*8+0]])
-# define C1(K,i) (((u64_a1*)(Cx.c+7))[2*K.c[(i)*8+1]])
-# define C2(K,i) (((u64_a1*)(Cx.c+6))[2*K.c[(i)*8+2]])
-# define C3(K,i) (((u64_a1*)(Cx.c+5))[2*K.c[(i)*8+3]])
-# define C4(K,i) (((u64_a1*)(Cx.c+4))[2*K.c[(i)*8+4]])
-# define C5(K,i) (((u64_a1*)(Cx.c+3))[2*K.c[(i)*8+5]])
-# define C6(K,i) (((u64_a1*)(Cx.c+2))[2*K.c[(i)*8+6]])
-# define C7(K,i) (((u64_a1*)(Cx.c+1))[2*K.c[(i)*8+7]])
+# define C1(K,i) (((u64_a1*)(Cx.c+7))[2*K.c[(i)*8+1]])
+# define C2(K,i) (((u64_a1*)(Cx.c+6))[2*K.c[(i)*8+2]])
+# define C3(K,i) (((u64_a1*)(Cx.c+5))[2*K.c[(i)*8+3]])
+# define C4(K,i) (((u64_a1*)(Cx.c+4))[2*K.c[(i)*8+4]])
+# define C5(K,i) (((u64_a1*)(Cx.c+3))[2*K.c[(i)*8+5]])
+# define C6(K,i) (((u64_a1*)(Cx.c+2))[2*K.c[(i)*8+6]])
+# define C7(K,i) (((u64_a1*)(Cx.c+1))[2*K.c[(i)*8+7]])
#endif
static const
@@ -545,7 +545,7 @@ void whirlpool_block(WHIRLPOOL_CTX *ctx, const void *inp, size_t n)
} else
# endif
{
- const u64_aX *pa = (const u64_aX *)p;
+ const u64_aX *pa = (const u64_aX *)p;
S.q[0] = (K.q[0] = H->q[0]) ^ pa[0];
S.q[1] = (K.q[1] = H->q[1]) ^ pa[1];
S.q[2] = (K.q[2] = H->q[2]) ^ pa[2];
@@ -783,7 +783,7 @@ void whirlpool_block(WHIRLPOOL_CTX *ctx, const void *inp, size_t n)
} else
# endif
{
- const u64_aX *pa = (const u64_aX *)p;
+ const u64_aX *pa = (const u64_aX *)p;
H->q[0] ^= S.q[0] ^ pa[0];
H->q[1] ^= S.q[1] ^ pa[1];
H->q[2] ^= S.q[2] ^ pa[2];
diff --git a/contrib/libs/openssl/crypto/x509/t_x509.c b/contrib/libs/openssl/crypto/x509/t_x509.c
index 9f872c7d13..ece987a6bd 100644
--- a/contrib/libs/openssl/crypto/x509/t_x509.c
+++ b/contrib/libs/openssl/crypto/x509/t_x509.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -365,9 +365,9 @@ int X509_aux_print(BIO *out, X509 *x, int indent)
BIO_puts(out, "\n");
} else
BIO_printf(out, "%*sNo Rejected Uses.\n", indent, "");
- alias = X509_alias_get0(x, &i);
+ alias = X509_alias_get0(x, &i);
if (alias)
- BIO_printf(out, "%*sAlias: %.*s\n", indent, "", i, alias);
+ BIO_printf(out, "%*sAlias: %.*s\n", indent, "", i, alias);
keyid = X509_keyid_get0(x, &keyidlen);
if (keyid) {
BIO_printf(out, "%*sKey Id: ", indent, "");
diff --git a/contrib/libs/openssl/crypto/x509/x509_att.c b/contrib/libs/openssl/crypto/x509/x509_att.c
index 998a5b3c44..cc9f9d1909 100644
--- a/contrib/libs/openssl/crypto/x509/x509_att.c
+++ b/contrib/libs/openssl/crypto/x509/x509_att.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -149,7 +149,7 @@ STACK_OF(X509_ATTRIBUTE) *X509at_add1_attr_by_txt(STACK_OF(X509_ATTRIBUTE)
return ret;
}
-void *X509at_get0_data_by_OBJ(const STACK_OF(X509_ATTRIBUTE) *x,
+void *X509at_get0_data_by_OBJ(const STACK_OF(X509_ATTRIBUTE) *x,
const ASN1_OBJECT *obj, int lastpos, int type)
{
int i;
diff --git a/contrib/libs/openssl/crypto/x509/x509_cmp.c b/contrib/libs/openssl/crypto/x509/x509_cmp.c
index 7c00c644fc..1d8d2d7b28 100644
--- a/contrib/libs/openssl/crypto/x509/x509_cmp.c
+++ b/contrib/libs/openssl/crypto/x509/x509_cmp.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -39,8 +39,8 @@ unsigned long X509_issuer_and_serial_hash(X509 *a)
if (ctx == NULL)
goto err;
f = X509_NAME_oneline(a->cert_info.issuer, NULL, 0);
- if (f == NULL)
- goto err;
+ if (f == NULL)
+ goto err;
if (!EVP_DigestInit_ex(ctx, EVP_md5(), NULL))
goto err;
if (!EVP_DigestUpdate(ctx, (unsigned char *)f, strlen(f)))
@@ -135,21 +135,21 @@ unsigned long X509_subject_name_hash_old(X509 *x)
*/
int X509_cmp(const X509 *a, const X509 *b)
{
- int rv = 0;
-
- if (a == b) /* for efficiency */
- return 0;
-
- /* try to make sure hash is valid */
- (void)X509_check_purpose((X509 *)a, -1, 0);
- (void)X509_check_purpose((X509 *)b, -1, 0);
-
- if ((a->ex_flags & EXFLAG_NO_FINGERPRINT) == 0
- && (b->ex_flags & EXFLAG_NO_FINGERPRINT) == 0)
- rv = memcmp(a->sha1_hash, b->sha1_hash, SHA_DIGEST_LENGTH);
- if (rv != 0)
+ int rv = 0;
+
+ if (a == b) /* for efficiency */
+ return 0;
+
+ /* try to make sure hash is valid */
+ (void)X509_check_purpose((X509 *)a, -1, 0);
+ (void)X509_check_purpose((X509 *)b, -1, 0);
+
+ if ((a->ex_flags & EXFLAG_NO_FINGERPRINT) == 0
+ && (b->ex_flags & EXFLAG_NO_FINGERPRINT) == 0)
+ rv = memcmp(a->sha1_hash, b->sha1_hash, SHA_DIGEST_LENGTH);
+ if (rv != 0)
return rv;
-
+
/* Check for match against stored encoding too */
if (!a->cert_info.enc.modified && !b->cert_info.enc.modified) {
if (a->cert_info.enc.len < b->cert_info.enc.len)
diff --git a/contrib/libs/openssl/crypto/x509/x509_err.c b/contrib/libs/openssl/crypto/x509/x509_err.c
index d5384a6206..bdd1e67cd3 100644
--- a/contrib/libs/openssl/crypto/x509/x509_err.c
+++ b/contrib/libs/openssl/crypto/x509/x509_err.c
@@ -1,6 +1,6 @@
/*
* Generated by util/mkerr.pl DO NOT EDIT
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -79,7 +79,7 @@ static const ERR_STRING_DATA X509_str_functs[] = {
{ERR_PACK(ERR_LIB_X509, X509_F_X509_PRINT_EX_FP, 0), "X509_print_ex_fp"},
{ERR_PACK(ERR_LIB_X509, X509_F_X509_PUBKEY_DECODE, 0),
"x509_pubkey_decode"},
- {ERR_PACK(ERR_LIB_X509, X509_F_X509_PUBKEY_GET, 0), "X509_PUBKEY_get"},
+ {ERR_PACK(ERR_LIB_X509, X509_F_X509_PUBKEY_GET, 0), "X509_PUBKEY_get"},
{ERR_PACK(ERR_LIB_X509, X509_F_X509_PUBKEY_GET0, 0), "X509_PUBKEY_get0"},
{ERR_PACK(ERR_LIB_X509, X509_F_X509_PUBKEY_SET, 0), "X509_PUBKEY_set"},
{ERR_PACK(ERR_LIB_X509, X509_F_X509_REQ_CHECK_PRIVATE_KEY, 0),
diff --git a/contrib/libs/openssl/crypto/x509/x509_local.h b/contrib/libs/openssl/crypto/x509/x509_local.h
index 23987859a5..10807e1def 100644
--- a/contrib/libs/openssl/crypto/x509/x509_local.h
+++ b/contrib/libs/openssl/crypto/x509/x509_local.h
@@ -1,5 +1,5 @@
/*
- * Copyright 2014-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2014-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -145,5 +145,5 @@ DEFINE_STACK_OF(STACK_OF_X509_NAME_ENTRY)
void x509_set_signature_info(X509_SIG_INFO *siginf, const X509_ALGOR *alg,
const ASN1_STRING *sig);
-int x509_likely_issued(X509 *issuer, X509 *subject);
-int x509_signing_allowed(const X509 *issuer, const X509 *subject);
+int x509_likely_issued(X509 *issuer, X509 *subject);
+int x509_signing_allowed(const X509 *issuer, const X509 *subject);
diff --git a/contrib/libs/openssl/crypto/x509/x509_req.c b/contrib/libs/openssl/crypto/x509/x509_req.c
index 1a70be5cfd..dd674926dd 100644
--- a/contrib/libs/openssl/crypto/x509/x509_req.c
+++ b/contrib/libs/openssl/crypto/x509/x509_req.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -286,18 +286,18 @@ void X509_REQ_get0_signature(const X509_REQ *req, const ASN1_BIT_STRING **psig,
*palg = &req->sig_alg;
}
-void X509_REQ_set0_signature(X509_REQ *req, ASN1_BIT_STRING *psig)
-{
- if (req->signature)
- ASN1_BIT_STRING_free(req->signature);
- req->signature = psig;
-}
-
-int X509_REQ_set1_signature_algo(X509_REQ *req, X509_ALGOR *palg)
-{
- return X509_ALGOR_copy(&req->sig_alg, palg);
-}
-
+void X509_REQ_set0_signature(X509_REQ *req, ASN1_BIT_STRING *psig)
+{
+ if (req->signature)
+ ASN1_BIT_STRING_free(req->signature);
+ req->signature = psig;
+}
+
+int X509_REQ_set1_signature_algo(X509_REQ *req, X509_ALGOR *palg)
+{
+ return X509_ALGOR_copy(&req->sig_alg, palg);
+}
+
int X509_REQ_get_signature_nid(const X509_REQ *req)
{
return OBJ_obj2nid(req->sig_alg.algorithm);
diff --git a/contrib/libs/openssl/crypto/x509/x509_txt.c b/contrib/libs/openssl/crypto/x509/x509_txt.c
index 8b15e957b7..02bde640d8 100644
--- a/contrib/libs/openssl/crypto/x509/x509_txt.c
+++ b/contrib/libs/openssl/crypto/x509/x509_txt.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -174,8 +174,8 @@ const char *X509_verify_cert_error_string(long n)
return "OCSP verification failed";
case X509_V_ERR_OCSP_CERT_UNKNOWN:
return "OCSP unknown cert";
- case X509_V_ERR_EC_KEY_EXPLICIT_PARAMS:
- return "Certificate public key has explicit ECC parameters";
+ case X509_V_ERR_EC_KEY_EXPLICIT_PARAMS:
+ return "Certificate public key has explicit ECC parameters";
default:
/* Printing an error number into a static buffer is not thread-safe */
diff --git a/contrib/libs/openssl/crypto/x509/x509_vfy.c b/contrib/libs/openssl/crypto/x509/x509_vfy.c
index bb787e8dda..20a36e763c 100644
--- a/contrib/libs/openssl/crypto/x509/x509_vfy.c
+++ b/contrib/libs/openssl/crypto/x509/x509_vfy.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -80,7 +80,7 @@ static int get_issuer_sk(X509 **issuer, X509_STORE_CTX *ctx, X509 *x);
static int check_dane_issuer(X509_STORE_CTX *ctx, int depth);
static int check_key_level(X509_STORE_CTX *ctx, X509 *cert);
static int check_sig_level(X509_STORE_CTX *ctx, X509 *cert);
-static int check_curve(X509 *cert);
+static int check_curve(X509 *cert);
static int get_crl_score(X509_STORE_CTX *ctx, X509 **pissuer,
unsigned int *preasons, X509_CRL *crl, X509 *x);
@@ -105,12 +105,12 @@ static int null_callback(int ok, X509_STORE_CTX *e)
return ok;
}
-/*
- * Return 1 if given cert is considered self-signed, 0 if not or on error.
- * This does not verify self-signedness but relies on x509v3_cache_extensions()
- * matching issuer and subject names (i.e., the cert being self-issued) and any
- * present authority key identifier matching the subject key identifier, etc.
- */
+/*
+ * Return 1 if given cert is considered self-signed, 0 if not or on error.
+ * This does not verify self-signedness but relies on x509v3_cache_extensions()
+ * matching issuer and subject names (i.e., the cert being self-issued) and any
+ * present authority key identifier matching the subject key identifier, etc.
+ */
static int cert_self_signed(X509 *x)
{
if (X509_check_purpose(x, -1, 0) != 1)
@@ -137,9 +137,9 @@ static X509 *lookup_cert_match(X509_STORE_CTX *ctx, X509 *x)
xtmp = sk_X509_value(certs, i);
if (!X509_cmp(xtmp, x))
break;
- xtmp = NULL;
+ xtmp = NULL;
}
- if (xtmp != NULL && !X509_up_ref(xtmp))
+ if (xtmp != NULL && !X509_up_ref(xtmp))
xtmp = NULL;
sk_X509_pop_free(certs, X509_free);
return xtmp;
@@ -272,24 +272,24 @@ int X509_verify_cert(X509_STORE_CTX *ctx)
return -1;
}
- if (!X509_up_ref(ctx->cert)) {
- X509err(X509_F_X509_VERIFY_CERT, ERR_R_INTERNAL_ERROR);
- ctx->error = X509_V_ERR_UNSPECIFIED;
- return -1;
- }
-
+ if (!X509_up_ref(ctx->cert)) {
+ X509err(X509_F_X509_VERIFY_CERT, ERR_R_INTERNAL_ERROR);
+ ctx->error = X509_V_ERR_UNSPECIFIED;
+ return -1;
+ }
+
/*
* first we make sure the chain we are going to build is present and that
* the first entry is in place
*/
- if ((ctx->chain = sk_X509_new_null()) == NULL
- || !sk_X509_push(ctx->chain, ctx->cert)) {
- X509_free(ctx->cert);
+ if ((ctx->chain = sk_X509_new_null()) == NULL
+ || !sk_X509_push(ctx->chain, ctx->cert)) {
+ X509_free(ctx->cert);
X509err(X509_F_X509_VERIFY_CERT, ERR_R_MALLOC_FAILURE);
ctx->error = X509_V_ERR_OUT_OF_MEM;
return -1;
}
-
+
ctx->num_untrusted = 1;
/* If the peer's public key is too weak, we can stop early. */
@@ -312,21 +312,21 @@ int X509_verify_cert(X509_STORE_CTX *ctx)
return ret;
}
-static int sk_X509_contains(STACK_OF(X509) *sk, X509 *cert)
-{
- int i, n = sk_X509_num(sk);
-
- for (i = 0; i < n; i++)
- if (X509_cmp(sk_X509_value(sk, i), cert) == 0)
- return 1;
- return 0;
-}
-
+static int sk_X509_contains(STACK_OF(X509) *sk, X509 *cert)
+{
+ int i, n = sk_X509_num(sk);
+
+ for (i = 0; i < n; i++)
+ if (X509_cmp(sk_X509_value(sk, i), cert) == 0)
+ return 1;
+ return 0;
+}
+
/*
- * Find in given STACK_OF(X509) sk an issuer cert of given cert x.
- * The issuer must not yet be in ctx->chain, where the exceptional case
- * that x is self-issued and ctx->chain has just one element is allowed.
- * Prefer the first one that is not expired, else take the last expired one.
+ * Find in given STACK_OF(X509) sk an issuer cert of given cert x.
+ * The issuer must not yet be in ctx->chain, where the exceptional case
+ * that x is self-issued and ctx->chain has just one element is allowed.
+ * Prefer the first one that is not expired, else take the last expired one.
*/
static X509 *find_issuer(X509_STORE_CTX *ctx, STACK_OF(X509) *sk, X509 *x)
{
@@ -335,9 +335,9 @@ static X509 *find_issuer(X509_STORE_CTX *ctx, STACK_OF(X509) *sk, X509 *x)
for (i = 0; i < sk_X509_num(sk); i++) {
issuer = sk_X509_value(sk, i);
- if (ctx->check_issued(ctx, x, issuer)
- && (((x->ex_flags & EXFLAG_SI) != 0 && sk_X509_num(ctx->chain) == 1)
- || !sk_X509_contains(ctx->chain, issuer))) {
+ if (ctx->check_issued(ctx, x, issuer)
+ && (((x->ex_flags & EXFLAG_SI) != 0 && sk_X509_num(ctx->chain) == 1)
+ || !sk_X509_contains(ctx->chain, issuer))) {
rv = issuer;
if (x509_check_cert_time(ctx, rv, -1))
break;
@@ -346,25 +346,25 @@ static X509 *find_issuer(X509_STORE_CTX *ctx, STACK_OF(X509) *sk, X509 *x)
return rv;
}
-/* Check that the given certificate 'x' is issued by the certificate 'issuer' */
+/* Check that the given certificate 'x' is issued by the certificate 'issuer' */
static int check_issued(X509_STORE_CTX *ctx, X509 *x, X509 *issuer)
{
- return x509_likely_issued(issuer, x) == X509_V_OK;
+ return x509_likely_issued(issuer, x) == X509_V_OK;
}
/* Alternative lookup method: look from a STACK stored in other_ctx */
static int get_issuer_sk(X509 **issuer, X509_STORE_CTX *ctx, X509 *x)
{
*issuer = find_issuer(ctx, ctx->other_ctx, x);
-
- if (*issuer == NULL || !X509_up_ref(*issuer))
- goto err;
-
- return 1;
-
- err:
- *issuer = NULL;
- return 0;
+
+ if (*issuer == NULL || !X509_up_ref(*issuer))
+ goto err;
+
+ return 1;
+
+ err:
+ *issuer = NULL;
+ return 0;
}
static STACK_OF(X509) *lookup_certs_sk(X509_STORE_CTX *ctx, X509_NAME *nm)
@@ -376,16 +376,16 @@ static STACK_OF(X509) *lookup_certs_sk(X509_STORE_CTX *ctx, X509_NAME *nm)
for (i = 0; i < sk_X509_num(ctx->other_ctx); i++) {
x = sk_X509_value(ctx->other_ctx, i);
if (X509_NAME_cmp(nm, X509_get_subject_name(x)) == 0) {
- if (!X509_up_ref(x)) {
- sk_X509_pop_free(sk, X509_free);
- X509err(X509_F_LOOKUP_CERTS_SK, ERR_R_INTERNAL_ERROR);
- ctx->error = X509_V_ERR_UNSPECIFIED;
- return NULL;
- }
+ if (!X509_up_ref(x)) {
+ sk_X509_pop_free(sk, X509_free);
+ X509err(X509_F_LOOKUP_CERTS_SK, ERR_R_INTERNAL_ERROR);
+ ctx->error = X509_V_ERR_UNSPECIFIED;
+ return NULL;
+ }
if (sk == NULL)
sk = sk_X509_new_null();
- if (sk == NULL || !sk_X509_push(sk, x)) {
- X509_free(x);
+ if (sk == NULL || !sk_X509_push(sk, x)) {
+ X509_free(x);
sk_X509_pop_free(sk, X509_free);
X509err(X509_F_LOOKUP_CERTS_SK, ERR_R_MALLOC_FAILURE);
ctx->error = X509_V_ERR_OUT_OF_MEM;
@@ -524,19 +524,19 @@ static int check_chain_extensions(X509_STORE_CTX *ctx)
ret = 1;
break;
}
- if (ret > 0
- && (ctx->param->flags & X509_V_FLAG_X509_STRICT) && num > 1) {
- /* Check for presence of explicit elliptic curve parameters */
- ret = check_curve(x);
- if (ret < 0) {
- ctx->error = X509_V_ERR_UNSPECIFIED;
- ret = 0;
- } else if (ret == 0) {
- ctx->error = X509_V_ERR_EC_KEY_EXPLICIT_PARAMS;
- }
- }
- if (ret > 0
- && (x->ex_flags & EXFLAG_CA) == 0
+ if (ret > 0
+ && (ctx->param->flags & X509_V_FLAG_X509_STRICT) && num > 1) {
+ /* Check for presence of explicit elliptic curve parameters */
+ ret = check_curve(x);
+ if (ret < 0) {
+ ctx->error = X509_V_ERR_UNSPECIFIED;
+ ret = 0;
+ } else if (ret == 0) {
+ ctx->error = X509_V_ERR_EC_KEY_EXPLICIT_PARAMS;
+ }
+ }
+ if (ret > 0
+ && (x->ex_flags & EXFLAG_CA) == 0
&& x->ex_pathlen != -1
&& (ctx->param->flags & X509_V_FLAG_X509_STRICT)) {
ctx->error = X509_V_ERR_INVALID_EXTENSION;
@@ -1727,7 +1727,7 @@ int x509_check_cert_time(X509_STORE_CTX *ctx, X509 *x, int depth)
return 1;
}
-/* verify the issuer signatures and cert times of ctx->chain */
+/* verify the issuer signatures and cert times of ctx->chain */
static int internal_verify(X509_STORE_CTX *ctx)
{
int n = sk_X509_num(ctx->chain) - 1;
@@ -1742,25 +1742,25 @@ static int internal_verify(X509_STORE_CTX *ctx)
if (ctx->bare_ta_signed) {
xs = xi;
xi = NULL;
- goto check_cert_time;
+ goto check_cert_time;
}
if (ctx->check_issued(ctx, xi, xi))
- xs = xi; /* the typical case: last cert in the chain is self-issued */
+ xs = xi; /* the typical case: last cert in the chain is self-issued */
else {
if (ctx->param->flags & X509_V_FLAG_PARTIAL_CHAIN) {
xs = xi;
- goto check_cert_time;
+ goto check_cert_time;
+ }
+ if (n <= 0) {
+ if (!verify_cb_cert(ctx, xi, 0,
+ X509_V_ERR_UNABLE_TO_VERIFY_LEAF_SIGNATURE))
+ return 0;
+
+ xs = xi;
+ goto check_cert_time;
}
- if (n <= 0) {
- if (!verify_cb_cert(ctx, xi, 0,
- X509_V_ERR_UNABLE_TO_VERIFY_LEAF_SIGNATURE))
- return 0;
-
- xs = xi;
- goto check_cert_time;
- }
-
+
n--;
ctx->error_depth = n;
xs = sk_X509_value(ctx->chain, n);
@@ -1772,54 +1772,54 @@ static int internal_verify(X509_STORE_CTX *ctx)
*/
while (n >= 0) {
/*
- * For each iteration of this loop:
- * n is the subject depth
- * xs is the subject cert, for which the signature is to be checked
- * xi is the supposed issuer cert containing the public key to use
- * Initially xs == xi if the last cert in the chain is self-issued.
- *
- * Skip signature check for self-signed certificates unless explicitly
- * asked for because it does not add any security and just wastes time.
+ * For each iteration of this loop:
+ * n is the subject depth
+ * xs is the subject cert, for which the signature is to be checked
+ * xi is the supposed issuer cert containing the public key to use
+ * Initially xs == xi if the last cert in the chain is self-issued.
+ *
+ * Skip signature check for self-signed certificates unless explicitly
+ * asked for because it does not add any security and just wastes time.
*/
- if (xs != xi || ((ctx->param->flags & X509_V_FLAG_CHECK_SS_SIGNATURE)
- && (xi->ex_flags & EXFLAG_SS) != 0)) {
- EVP_PKEY *pkey;
- /*
- * If the issuer's public key is not available or its key usage
- * does not support issuing the subject cert, report the issuer
- * cert and its depth (rather than n, the depth of the subject).
- */
- int issuer_depth = n + (xs == xi ? 0 : 1);
- /*
- * According to https://tools.ietf.org/html/rfc5280#section-6.1.4
- * step (n) we must check any given key usage extension in a CA cert
- * when preparing the verification of a certificate issued by it.
- * According to https://tools.ietf.org/html/rfc5280#section-4.2.1.3
- * we must not verify a certifiate signature if the key usage of the
- * CA certificate that issued the certificate prohibits signing.
- * In case the 'issuing' certificate is the last in the chain and is
- * not a CA certificate but a 'self-issued' end-entity cert (i.e.,
- * xs == xi && !(xi->ex_flags & EXFLAG_CA)) RFC 5280 does not apply
- * (see https://tools.ietf.org/html/rfc6818#section-2) and thus
- * we are free to ignore any key usage restrictions on such certs.
- */
- int ret = xs == xi && (xi->ex_flags & EXFLAG_CA) == 0
- ? X509_V_OK : x509_signing_allowed(xi, xs);
-
- if (ret != X509_V_OK && !verify_cb_cert(ctx, xi, issuer_depth, ret))
- return 0;
+ if (xs != xi || ((ctx->param->flags & X509_V_FLAG_CHECK_SS_SIGNATURE)
+ && (xi->ex_flags & EXFLAG_SS) != 0)) {
+ EVP_PKEY *pkey;
+ /*
+ * If the issuer's public key is not available or its key usage
+ * does not support issuing the subject cert, report the issuer
+ * cert and its depth (rather than n, the depth of the subject).
+ */
+ int issuer_depth = n + (xs == xi ? 0 : 1);
+ /*
+ * According to https://tools.ietf.org/html/rfc5280#section-6.1.4
+ * step (n) we must check any given key usage extension in a CA cert
+ * when preparing the verification of a certificate issued by it.
+ * According to https://tools.ietf.org/html/rfc5280#section-4.2.1.3
+ * we must not verify a certifiate signature if the key usage of the
+ * CA certificate that issued the certificate prohibits signing.
+ * In case the 'issuing' certificate is the last in the chain and is
+ * not a CA certificate but a 'self-issued' end-entity cert (i.e.,
+ * xs == xi && !(xi->ex_flags & EXFLAG_CA)) RFC 5280 does not apply
+ * (see https://tools.ietf.org/html/rfc6818#section-2) and thus
+ * we are free to ignore any key usage restrictions on such certs.
+ */
+ int ret = xs == xi && (xi->ex_flags & EXFLAG_CA) == 0
+ ? X509_V_OK : x509_signing_allowed(xi, xs);
+
+ if (ret != X509_V_OK && !verify_cb_cert(ctx, xi, issuer_depth, ret))
+ return 0;
if ((pkey = X509_get0_pubkey(xi)) == NULL) {
- ret = X509_V_ERR_UNABLE_TO_DECODE_ISSUER_PUBLIC_KEY;
- if (!verify_cb_cert(ctx, xi, issuer_depth, ret))
+ ret = X509_V_ERR_UNABLE_TO_DECODE_ISSUER_PUBLIC_KEY;
+ if (!verify_cb_cert(ctx, xi, issuer_depth, ret))
return 0;
} else if (X509_verify(xs, pkey) <= 0) {
- ret = X509_V_ERR_CERT_SIGNATURE_FAILURE;
- if (!verify_cb_cert(ctx, xs, n, ret))
+ ret = X509_V_ERR_CERT_SIGNATURE_FAILURE;
+ if (!verify_cb_cert(ctx, xs, n, ret))
return 0;
}
}
- check_cert_time: /* in addition to RFC 5280, do also for trusted (root) cert */
+ check_cert_time: /* in addition to RFC 5280, do also for trusted (root) cert */
/* Calls verify callback as needed */
if (!x509_check_cert_time(ctx, xs, n))
return 0;
@@ -3221,16 +3221,16 @@ static int build_chain(X509_STORE_CTX *ctx)
/* Drop this issuer from future consideration */
(void) sk_X509_delete_ptr(sktmp, xtmp);
- if (!X509_up_ref(xtmp)) {
- X509err(X509_F_BUILD_CHAIN, ERR_R_INTERNAL_ERROR);
- trust = X509_TRUST_REJECTED;
- ctx->error = X509_V_ERR_UNSPECIFIED;
- search = 0;
- continue;
- }
-
+ if (!X509_up_ref(xtmp)) {
+ X509err(X509_F_BUILD_CHAIN, ERR_R_INTERNAL_ERROR);
+ trust = X509_TRUST_REJECTED;
+ ctx->error = X509_V_ERR_UNSPECIFIED;
+ search = 0;
+ continue;
+ }
+
if (!sk_X509_push(ctx->chain, xtmp)) {
- X509_free(xtmp);
+ X509_free(xtmp);
X509err(X509_F_BUILD_CHAIN, ERR_R_MALLOC_FAILURE);
trust = X509_TRUST_REJECTED;
ctx->error = X509_V_ERR_OUT_OF_MEM;
@@ -3238,7 +3238,7 @@ static int build_chain(X509_STORE_CTX *ctx)
continue;
}
- x = xtmp;
+ x = xtmp;
++ctx->num_untrusted;
ss = cert_self_signed(xtmp);
@@ -3330,32 +3330,32 @@ static int check_key_level(X509_STORE_CTX *ctx, X509 *cert)
}
/*
- * Check whether the public key of ``cert`` does not use explicit params
- * for an elliptic curve.
- *
- * Returns 1 on success, 0 if check fails, -1 for other errors.
- */
-static int check_curve(X509 *cert)
-{
-#ifndef OPENSSL_NO_EC
- EVP_PKEY *pkey = X509_get0_pubkey(cert);
-
- /* Unsupported or malformed key */
- if (pkey == NULL)
- return -1;
-
- if (EVP_PKEY_id(pkey) == EVP_PKEY_EC) {
- int ret;
-
- ret = EC_KEY_decoded_from_explicit_params(EVP_PKEY_get0_EC_KEY(pkey));
- return ret < 0 ? ret : !ret;
- }
-#endif
-
- return 1;
-}
-
-/*
+ * Check whether the public key of ``cert`` does not use explicit params
+ * for an elliptic curve.
+ *
+ * Returns 1 on success, 0 if check fails, -1 for other errors.
+ */
+static int check_curve(X509 *cert)
+{
+#ifndef OPENSSL_NO_EC
+ EVP_PKEY *pkey = X509_get0_pubkey(cert);
+
+ /* Unsupported or malformed key */
+ if (pkey == NULL)
+ return -1;
+
+ if (EVP_PKEY_id(pkey) == EVP_PKEY_EC) {
+ int ret;
+
+ ret = EC_KEY_decoded_from_explicit_params(EVP_PKEY_get0_EC_KEY(pkey));
+ return ret < 0 ? ret : !ret;
+ }
+#endif
+
+ return 1;
+}
+
+/*
* Check whether the signature digest algorithm of ``cert`` meets the security
* level of ``ctx``. Should not be checked for trust anchors (whether
* self-signed or otherwise).
diff --git a/contrib/libs/openssl/crypto/x509/x509_vpm.c b/contrib/libs/openssl/crypto/x509/x509_vpm.c
index 75b3600d01..535f169a29 100644
--- a/contrib/libs/openssl/crypto/x509/x509_vpm.c
+++ b/contrib/libs/openssl/crypto/x509/x509_vpm.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2004-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2004-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -199,8 +199,8 @@ int X509_VERIFY_PARAM_inherit(X509_VERIFY_PARAM *dest,
return 0;
}
- x509_verify_param_copy(hostflags, 0);
-
+ x509_verify_param_copy(hostflags, 0);
+
if (test_x509_verify_param_copy(hosts, NULL)) {
sk_OPENSSL_STRING_pop_free(dest->hosts, str_free);
dest->hosts = NULL;
diff --git a/contrib/libs/openssl/crypto/x509/x_all.c b/contrib/libs/openssl/crypto/x509/x_all.c
index a45f90e6f3..a4e9cdaee8 100644
--- a/contrib/libs/openssl/crypto/x509/x_all.c
+++ b/contrib/libs/openssl/crypto/x509/x_all.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -363,7 +363,7 @@ int X509_digest(const X509 *data, const EVP_MD *type, unsigned char *md,
unsigned int *len)
{
if (type == EVP_sha1() && (data->ex_flags & EXFLAG_SET) != 0
- && (data->ex_flags & EXFLAG_NO_FINGERPRINT) == 0) {
+ && (data->ex_flags & EXFLAG_NO_FINGERPRINT) == 0) {
/* Asking for SHA1 and we already computed it. */
if (len != NULL)
*len = sizeof(data->sha1_hash);
diff --git a/contrib/libs/openssl/crypto/x509/x_attrib.c b/contrib/libs/openssl/crypto/x509/x_attrib.c
index 8823fa5382..7342c4f6bc 100644
--- a/contrib/libs/openssl/crypto/x509/x_attrib.c
+++ b/contrib/libs/openssl/crypto/x509/x_attrib.c
@@ -37,13 +37,13 @@ X509_ATTRIBUTE *X509_ATTRIBUTE_create(int nid, int atrtype, void *value)
{
X509_ATTRIBUTE *ret = NULL;
ASN1_TYPE *val = NULL;
- ASN1_OBJECT *oid;
+ ASN1_OBJECT *oid;
- if ((oid = OBJ_nid2obj(nid)) == NULL)
- return NULL;
+ if ((oid = OBJ_nid2obj(nid)) == NULL)
+ return NULL;
if ((ret = X509_ATTRIBUTE_new()) == NULL)
return NULL;
- ret->object = oid;
+ ret->object = oid;
if ((val = ASN1_TYPE_new()) == NULL)
goto err;
if (!sk_ASN1_TYPE_push(ret->set, val))
diff --git a/contrib/libs/openssl/crypto/x509/x_pubkey.c b/contrib/libs/openssl/crypto/x509/x_pubkey.c
index aa86785d44..9be7e92865 100644
--- a/contrib/libs/openssl/crypto/x509/x_pubkey.c
+++ b/contrib/libs/openssl/crypto/x509/x_pubkey.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -169,11 +169,11 @@ EVP_PKEY *X509_PUBKEY_get0(X509_PUBKEY *key)
EVP_PKEY *X509_PUBKEY_get(X509_PUBKEY *key)
{
EVP_PKEY *ret = X509_PUBKEY_get0(key);
-
- if (ret != NULL && !EVP_PKEY_up_ref(ret)) {
- X509err(X509_F_X509_PUBKEY_GET, ERR_R_INTERNAL_ERROR);
- ret = NULL;
- }
+
+ if (ret != NULL && !EVP_PKEY_up_ref(ret)) {
+ X509err(X509_F_X509_PUBKEY_GET, ERR_R_INTERNAL_ERROR);
+ ret = NULL;
+ }
return ret;
}
diff --git a/contrib/libs/openssl/crypto/x509v3/pcy_data.c b/contrib/libs/openssl/crypto/x509v3/pcy_data.c
index d8980f8fc3..8c7bc69576 100644
--- a/contrib/libs/openssl/crypto/x509v3/pcy_data.c
+++ b/contrib/libs/openssl/crypto/x509v3/pcy_data.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2004-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2004-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -52,7 +52,7 @@ X509_POLICY_DATA *policy_data_new(POLICYINFO *policy,
ret = OPENSSL_zalloc(sizeof(*ret));
if (ret == NULL) {
X509V3err(X509V3_F_POLICY_DATA_NEW, ERR_R_MALLOC_FAILURE);
- ASN1_OBJECT_free(id);
+ ASN1_OBJECT_free(id);
return NULL;
}
ret->expected_policy_set = sk_ASN1_OBJECT_new_null();
diff --git a/contrib/libs/openssl/crypto/x509v3/v3_akey.c b/contrib/libs/openssl/crypto/x509v3/v3_akey.c
index d48b2fccdb..33b1933d72 100644
--- a/contrib/libs/openssl/crypto/x509v3/v3_akey.c
+++ b/contrib/libs/openssl/crypto/x509v3/v3_akey.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -39,48 +39,48 @@ static STACK_OF(CONF_VALUE) *i2v_AUTHORITY_KEYID(X509V3_EXT_METHOD *method,
STACK_OF(CONF_VALUE)
*extlist)
{
- char *tmp = NULL;
- STACK_OF(CONF_VALUE) *origextlist = extlist, *tmpextlist;
-
+ char *tmp = NULL;
+ STACK_OF(CONF_VALUE) *origextlist = extlist, *tmpextlist;
+
if (akeyid->keyid) {
tmp = OPENSSL_buf2hexstr(akeyid->keyid->data, akeyid->keyid->length);
- if (tmp == NULL) {
- X509V3err(X509V3_F_I2V_AUTHORITY_KEYID, ERR_R_MALLOC_FAILURE);
- return NULL;
- }
- if (!X509V3_add_value("keyid", tmp, &extlist)) {
- OPENSSL_free(tmp);
- X509V3err(X509V3_F_I2V_AUTHORITY_KEYID, ERR_R_X509_LIB);
- goto err;
- }
+ if (tmp == NULL) {
+ X509V3err(X509V3_F_I2V_AUTHORITY_KEYID, ERR_R_MALLOC_FAILURE);
+ return NULL;
+ }
+ if (!X509V3_add_value("keyid", tmp, &extlist)) {
+ OPENSSL_free(tmp);
+ X509V3err(X509V3_F_I2V_AUTHORITY_KEYID, ERR_R_X509_LIB);
+ goto err;
+ }
OPENSSL_free(tmp);
}
- if (akeyid->issuer) {
- tmpextlist = i2v_GENERAL_NAMES(NULL, akeyid->issuer, extlist);
- if (tmpextlist == NULL) {
- X509V3err(X509V3_F_I2V_AUTHORITY_KEYID, ERR_R_X509_LIB);
- goto err;
- }
- extlist = tmpextlist;
- }
+ if (akeyid->issuer) {
+ tmpextlist = i2v_GENERAL_NAMES(NULL, akeyid->issuer, extlist);
+ if (tmpextlist == NULL) {
+ X509V3err(X509V3_F_I2V_AUTHORITY_KEYID, ERR_R_X509_LIB);
+ goto err;
+ }
+ extlist = tmpextlist;
+ }
if (akeyid->serial) {
tmp = OPENSSL_buf2hexstr(akeyid->serial->data, akeyid->serial->length);
- if (tmp == NULL) {
- X509V3err(X509V3_F_I2V_AUTHORITY_KEYID, ERR_R_MALLOC_FAILURE);
- goto err;
- }
- if (!X509V3_add_value("serial", tmp, &extlist)) {
- OPENSSL_free(tmp);
- X509V3err(X509V3_F_I2V_AUTHORITY_KEYID, ERR_R_X509_LIB);
- goto err;
- }
+ if (tmp == NULL) {
+ X509V3err(X509V3_F_I2V_AUTHORITY_KEYID, ERR_R_MALLOC_FAILURE);
+ goto err;
+ }
+ if (!X509V3_add_value("serial", tmp, &extlist)) {
+ OPENSSL_free(tmp);
+ X509V3err(X509V3_F_I2V_AUTHORITY_KEYID, ERR_R_X509_LIB);
+ goto err;
+ }
OPENSSL_free(tmp);
}
return extlist;
- err:
- if (origextlist == NULL)
- sk_CONF_VALUE_pop_free(extlist, X509V3_conf_free);
- return NULL;
+ err:
+ if (origextlist == NULL)
+ sk_CONF_VALUE_pop_free(extlist, X509V3_conf_free);
+ return NULL;
}
/*-
diff --git a/contrib/libs/openssl/crypto/x509v3/v3_alt.c b/contrib/libs/openssl/crypto/x509v3/v3_alt.c
index 160cb5969b..7c32d4031d 100644
--- a/contrib/libs/openssl/crypto/x509v3/v3_alt.c
+++ b/contrib/libs/openssl/crypto/x509v3/v3_alt.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -9,7 +9,7 @@
#include <stdio.h>
#include "internal/cryptlib.h"
-#include "crypto/x509.h"
+#include "crypto/x509.h"
#include <openssl/conf.h>
#include <openssl/x509v3.h>
#include "ext_dat.h"
@@ -100,20 +100,20 @@ STACK_OF(CONF_VALUE) *i2v_GENERAL_NAME(X509V3_EXT_METHOD *method,
break;
case GEN_EMAIL:
- if (!x509v3_add_len_value_uchar("email", gen->d.ia5->data,
- gen->d.ia5->length, &ret))
+ if (!x509v3_add_len_value_uchar("email", gen->d.ia5->data,
+ gen->d.ia5->length, &ret))
return NULL;
break;
case GEN_DNS:
- if (!x509v3_add_len_value_uchar("DNS", gen->d.ia5->data,
- gen->d.ia5->length, &ret))
+ if (!x509v3_add_len_value_uchar("DNS", gen->d.ia5->data,
+ gen->d.ia5->length, &ret))
return NULL;
break;
case GEN_URI:
- if (!x509v3_add_len_value_uchar("URI", gen->d.ia5->data,
- gen->d.ia5->length, &ret))
+ if (!x509v3_add_len_value_uchar("URI", gen->d.ia5->data,
+ gen->d.ia5->length, &ret))
return NULL;
break;
@@ -279,7 +279,7 @@ static int copy_issuer(X509V3_CTX *ctx, GENERAL_NAMES *gens)
num = sk_GENERAL_NAME_num(ialt);
if (!sk_GENERAL_NAME_reserve(gens, num)) {
X509V3err(X509V3_F_COPY_ISSUER, ERR_R_MALLOC_FAILURE);
- sk_GENERAL_NAME_free(ialt);
+ sk_GENERAL_NAME_free(ialt);
goto err;
}
diff --git a/contrib/libs/openssl/crypto/x509v3/v3_cpols.c b/contrib/libs/openssl/crypto/x509v3/v3_cpols.c
index 27d8cc62c0..09804b5848 100644
--- a/contrib/libs/openssl/crypto/x509v3/v3_cpols.c
+++ b/contrib/libs/openssl/crypto/x509v3/v3_cpols.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -422,8 +422,8 @@ static void print_qualifiers(BIO *out, STACK_OF(POLICYQUALINFO) *quals,
qualinfo = sk_POLICYQUALINFO_value(quals, i);
switch (OBJ_obj2nid(qualinfo->pqualid)) {
case NID_id_qt_cps:
- BIO_printf(out, "%*sCPS: %.*s\n", indent, "",
- qualinfo->d.cpsuri->length,
+ BIO_printf(out, "%*sCPS: %.*s\n", indent, "",
+ qualinfo->d.cpsuri->length,
qualinfo->d.cpsuri->data);
break;
@@ -448,8 +448,8 @@ static void print_notice(BIO *out, USERNOTICE *notice, int indent)
if (notice->noticeref) {
NOTICEREF *ref;
ref = notice->noticeref;
- BIO_printf(out, "%*sOrganization: %.*s\n", indent, "",
- ref->organization->length,
+ BIO_printf(out, "%*sOrganization: %.*s\n", indent, "",
+ ref->organization->length,
ref->organization->data);
BIO_printf(out, "%*sNumber%s: ", indent, "",
sk_ASN1_INTEGER_num(ref->noticenos) > 1 ? "s" : "");
@@ -472,8 +472,8 @@ static void print_notice(BIO *out, USERNOTICE *notice, int indent)
BIO_puts(out, "\n");
}
if (notice->exptext)
- BIO_printf(out, "%*sExplicit Text: %.*s\n", indent, "",
- notice->exptext->length,
+ BIO_printf(out, "%*sExplicit Text: %.*s\n", indent, "",
+ notice->exptext->length,
notice->exptext->data);
}
diff --git a/contrib/libs/openssl/crypto/x509v3/v3_genn.c b/contrib/libs/openssl/crypto/x509v3/v3_genn.c
index 85e9fa82c4..87a5eff47c 100644
--- a/contrib/libs/openssl/crypto/x509v3/v3_genn.c
+++ b/contrib/libs/openssl/crypto/x509v3/v3_genn.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1999-2020 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1999-2020 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -22,9 +22,9 @@ ASN1_SEQUENCE(OTHERNAME) = {
IMPLEMENT_ASN1_FUNCTIONS(OTHERNAME)
ASN1_SEQUENCE(EDIPARTYNAME) = {
- /* DirectoryString is a CHOICE type so use explicit tagging */
- ASN1_EXP_OPT(EDIPARTYNAME, nameAssigner, DIRECTORYSTRING, 0),
- ASN1_EXP(EDIPARTYNAME, partyName, DIRECTORYSTRING, 1)
+ /* DirectoryString is a CHOICE type so use explicit tagging */
+ ASN1_EXP_OPT(EDIPARTYNAME, nameAssigner, DIRECTORYSTRING, 0),
+ ASN1_EXP(EDIPARTYNAME, partyName, DIRECTORYSTRING, 1)
} ASN1_SEQUENCE_END(EDIPARTYNAME)
IMPLEMENT_ASN1_FUNCTIONS(EDIPARTYNAME)
@@ -58,37 +58,37 @@ GENERAL_NAME *GENERAL_NAME_dup(GENERAL_NAME *a)
(char *)a);
}
-static int edipartyname_cmp(const EDIPARTYNAME *a, const EDIPARTYNAME *b)
-{
- int res;
-
- if (a == NULL || b == NULL) {
- /*
- * Shouldn't be possible in a valid GENERAL_NAME, but we handle it
- * anyway. OTHERNAME_cmp treats NULL != NULL so we do the same here
- */
- return -1;
- }
- if (a->nameAssigner == NULL && b->nameAssigner != NULL)
- return -1;
- if (a->nameAssigner != NULL && b->nameAssigner == NULL)
- return 1;
- /* If we get here then both have nameAssigner set, or both unset */
- if (a->nameAssigner != NULL) {
- res = ASN1_STRING_cmp(a->nameAssigner, b->nameAssigner);
- if (res != 0)
- return res;
- }
- /*
- * partyName is required, so these should never be NULL. We treat it in
- * the same way as the a == NULL || b == NULL case above
- */
- if (a->partyName == NULL || b->partyName == NULL)
- return -1;
-
- return ASN1_STRING_cmp(a->partyName, b->partyName);
-}
-
+static int edipartyname_cmp(const EDIPARTYNAME *a, const EDIPARTYNAME *b)
+{
+ int res;
+
+ if (a == NULL || b == NULL) {
+ /*
+ * Shouldn't be possible in a valid GENERAL_NAME, but we handle it
+ * anyway. OTHERNAME_cmp treats NULL != NULL so we do the same here
+ */
+ return -1;
+ }
+ if (a->nameAssigner == NULL && b->nameAssigner != NULL)
+ return -1;
+ if (a->nameAssigner != NULL && b->nameAssigner == NULL)
+ return 1;
+ /* If we get here then both have nameAssigner set, or both unset */
+ if (a->nameAssigner != NULL) {
+ res = ASN1_STRING_cmp(a->nameAssigner, b->nameAssigner);
+ if (res != 0)
+ return res;
+ }
+ /*
+ * partyName is required, so these should never be NULL. We treat it in
+ * the same way as the a == NULL || b == NULL case above
+ */
+ if (a->partyName == NULL || b->partyName == NULL)
+ return -1;
+
+ return ASN1_STRING_cmp(a->partyName, b->partyName);
+}
+
/* Returns 0 if they are equal, != 0 otherwise. */
int GENERAL_NAME_cmp(GENERAL_NAME *a, GENERAL_NAME *b)
{
@@ -98,11 +98,11 @@ int GENERAL_NAME_cmp(GENERAL_NAME *a, GENERAL_NAME *b)
return -1;
switch (a->type) {
case GEN_X400:
- result = ASN1_TYPE_cmp(a->d.x400Address, b->d.x400Address);
- break;
-
+ result = ASN1_TYPE_cmp(a->d.x400Address, b->d.x400Address);
+ break;
+
case GEN_EDIPARTY:
- result = edipartyname_cmp(a->d.ediPartyName, b->d.ediPartyName);
+ result = edipartyname_cmp(a->d.ediPartyName, b->d.ediPartyName);
break;
case GEN_OTHERNAME:
@@ -149,11 +149,11 @@ void GENERAL_NAME_set0_value(GENERAL_NAME *a, int type, void *value)
{
switch (type) {
case GEN_X400:
- a->d.x400Address = value;
- break;
-
+ a->d.x400Address = value;
+ break;
+
case GEN_EDIPARTY:
- a->d.ediPartyName = value;
+ a->d.ediPartyName = value;
break;
case GEN_OTHERNAME:
@@ -187,10 +187,10 @@ void *GENERAL_NAME_get0_value(const GENERAL_NAME *a, int *ptype)
*ptype = a->type;
switch (a->type) {
case GEN_X400:
- return a->d.x400Address;
-
+ return a->d.x400Address;
+
case GEN_EDIPARTY:
- return a->d.ediPartyName;
+ return a->d.ediPartyName;
case GEN_OTHERNAME:
return a->d.otherName;
diff --git a/contrib/libs/openssl/crypto/x509v3/v3_ncons.c b/contrib/libs/openssl/crypto/x509v3/v3_ncons.c
index 74fcaed44e..d985aa91da 100644
--- a/contrib/libs/openssl/crypto/x509v3/v3_ncons.c
+++ b/contrib/libs/openssl/crypto/x509v3/v3_ncons.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2003-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2003-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -63,31 +63,31 @@ ASN1_SEQUENCE(NAME_CONSTRAINTS) = {
IMPLEMENT_ASN1_ALLOC_FUNCTIONS(GENERAL_SUBTREE)
IMPLEMENT_ASN1_ALLOC_FUNCTIONS(NAME_CONSTRAINTS)
-
-#define IA5_OFFSET_LEN(ia5base, offset) \
- ((ia5base)->length - ((unsigned char *)(offset) - (ia5base)->data))
-
-/* Like memchr but for ASN1_IA5STRING. Additionally you can specify the
- * starting point to search from
- */
-# define ia5memchr(str, start, c) memchr(start, c, IA5_OFFSET_LEN(str, start))
-
-/* Like memrrchr but for ASN1_IA5STRING */
-static char *ia5memrchr(ASN1_IA5STRING *str, int c)
-{
- int i;
-
- for (i = str->length; i > 0 && str->data[i - 1] != c; i--);
-
- if (i == 0)
- return NULL;
-
- return (char *)&str->data[i - 1];
-}
-
+
+#define IA5_OFFSET_LEN(ia5base, offset) \
+ ((ia5base)->length - ((unsigned char *)(offset) - (ia5base)->data))
+
+/* Like memchr but for ASN1_IA5STRING. Additionally you can specify the
+ * starting point to search from
+ */
+# define ia5memchr(str, start, c) memchr(start, c, IA5_OFFSET_LEN(str, start))
+
+/* Like memrrchr but for ASN1_IA5STRING */
+static char *ia5memrchr(ASN1_IA5STRING *str, int c)
+{
+ int i;
+
+ for (i = str->length; i > 0 && str->data[i - 1] != c; i--);
+
+ if (i == 0)
+ return NULL;
+
+ return (char *)&str->data[i - 1];
+}
+
/*
- * We cannot use strncasecmp here because that applies locale specific rules. It
- * also doesn't work with ASN1_STRINGs that may have embedded NUL characters.
+ * We cannot use strncasecmp here because that applies locale specific rules. It
+ * also doesn't work with ASN1_STRINGs that may have embedded NUL characters.
* For example in Turkish 'I' is not the uppercase character for 'i'. We need to
* do a simple ASCII case comparison ignoring the locale (that is why we use
* numeric constants below).
@@ -352,7 +352,7 @@ static int cn2dnsid(ASN1_STRING *cn, unsigned char **dnsid, size_t *idlen)
--utf8_length;
/* Reject *embedded* NULs */
- if (memchr(utf8_value, 0, utf8_length) != NULL) {
+ if (memchr(utf8_value, 0, utf8_length) != NULL) {
OPENSSL_free(utf8_value);
return X509_V_ERR_UNSUPPORTED_NAME_SYNTAX;
}
@@ -551,14 +551,14 @@ static int nc_dns(ASN1_IA5STRING *dns, ASN1_IA5STRING *base)
{
char *baseptr = (char *)base->data;
char *dnsptr = (char *)dns->data;
-
+
/* Empty matches everything */
- if (base->length == 0)
+ if (base->length == 0)
return X509_V_OK;
-
- if (dns->length < base->length)
- return X509_V_ERR_PERMITTED_VIOLATION;
-
+
+ if (dns->length < base->length)
+ return X509_V_ERR_PERMITTED_VIOLATION;
+
/*
* Otherwise can add zero or more components on the left so compare RHS
* and if dns is longer and expect '.' as preceding character.
@@ -569,7 +569,7 @@ static int nc_dns(ASN1_IA5STRING *dns, ASN1_IA5STRING *base)
return X509_V_ERR_PERMITTED_VIOLATION;
}
- if (ia5ncasecmp(baseptr, dnsptr, base->length))
+ if (ia5ncasecmp(baseptr, dnsptr, base->length))
return X509_V_ERR_PERMITTED_VIOLATION;
return X509_V_OK;
@@ -580,17 +580,17 @@ static int nc_email(ASN1_IA5STRING *eml, ASN1_IA5STRING *base)
{
const char *baseptr = (char *)base->data;
const char *emlptr = (char *)eml->data;
- const char *baseat = ia5memrchr(base, '@');
- const char *emlat = ia5memrchr(eml, '@');
- size_t basehostlen, emlhostlen;
+ const char *baseat = ia5memrchr(base, '@');
+ const char *emlat = ia5memrchr(eml, '@');
+ size_t basehostlen, emlhostlen;
if (!emlat)
return X509_V_ERR_UNSUPPORTED_NAME_SYNTAX;
/* Special case: initial '.' is RHS match */
- if (!baseat && base->length > 0 && (*baseptr == '.')) {
+ if (!baseat && base->length > 0 && (*baseptr == '.')) {
if (eml->length > base->length) {
emlptr += eml->length - base->length;
- if (ia5ncasecmp(baseptr, emlptr, base->length) == 0)
+ if (ia5ncasecmp(baseptr, emlptr, base->length) == 0)
return X509_V_OK;
}
return X509_V_ERR_PERMITTED_VIOLATION;
@@ -610,10 +610,10 @@ static int nc_email(ASN1_IA5STRING *eml, ASN1_IA5STRING *base)
baseptr = baseat + 1;
}
emlptr = emlat + 1;
- basehostlen = IA5_OFFSET_LEN(base, baseptr);
- emlhostlen = IA5_OFFSET_LEN(eml, emlptr);
+ basehostlen = IA5_OFFSET_LEN(base, baseptr);
+ emlhostlen = IA5_OFFSET_LEN(eml, emlptr);
/* Just have hostname left to match: case insensitive */
- if (basehostlen != emlhostlen || ia5ncasecmp(baseptr, emlptr, emlhostlen))
+ if (basehostlen != emlhostlen || ia5ncasecmp(baseptr, emlptr, emlhostlen))
return X509_V_ERR_PERMITTED_VIOLATION;
return X509_V_OK;
@@ -624,14 +624,14 @@ static int nc_uri(ASN1_IA5STRING *uri, ASN1_IA5STRING *base)
{
const char *baseptr = (char *)base->data;
const char *hostptr = (char *)uri->data;
- const char *p = ia5memchr(uri, (char *)uri->data, ':');
+ const char *p = ia5memchr(uri, (char *)uri->data, ':');
int hostlen;
-
+
/* Check for foo:// and skip past it */
- if (p == NULL
- || IA5_OFFSET_LEN(uri, p) < 3
- || p[1] != '/'
- || p[2] != '/')
+ if (p == NULL
+ || IA5_OFFSET_LEN(uri, p) < 3
+ || p[1] != '/'
+ || p[2] != '/')
return X509_V_ERR_UNSUPPORTED_NAME_SYNTAX;
hostptr = p + 3;
@@ -639,13 +639,13 @@ static int nc_uri(ASN1_IA5STRING *uri, ASN1_IA5STRING *base)
/* Look for a port indicator as end of hostname first */
- p = ia5memchr(uri, hostptr, ':');
+ p = ia5memchr(uri, hostptr, ':');
/* Otherwise look for trailing slash */
- if (p == NULL)
- p = ia5memchr(uri, hostptr, '/');
+ if (p == NULL)
+ p = ia5memchr(uri, hostptr, '/');
- if (p == NULL)
- hostlen = IA5_OFFSET_LEN(uri, hostptr);
+ if (p == NULL)
+ hostlen = IA5_OFFSET_LEN(uri, hostptr);
else
hostlen = p - hostptr;
@@ -653,7 +653,7 @@ static int nc_uri(ASN1_IA5STRING *uri, ASN1_IA5STRING *base)
return X509_V_ERR_UNSUPPORTED_NAME_SYNTAX;
/* Special case: initial '.' is RHS match */
- if (base->length > 0 && *baseptr == '.') {
+ if (base->length > 0 && *baseptr == '.') {
if (hostlen > base->length) {
p = hostptr + hostlen - base->length;
if (ia5ncasecmp(p, baseptr, base->length) == 0)
diff --git a/contrib/libs/openssl/crypto/x509v3/v3_pci.c b/contrib/libs/openssl/crypto/x509v3/v3_pci.c
index a4360f47ba..532d4e192f 100644
--- a/contrib/libs/openssl/crypto/x509v3/v3_pci.c
+++ b/contrib/libs/openssl/crypto/x509v3/v3_pci.c
@@ -1,5 +1,5 @@
/*
- * Copyright 2004-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2004-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -77,8 +77,8 @@ static int i2r_pci(X509V3_EXT_METHOD *method, PROXY_CERT_INFO_EXTENSION *pci,
i2a_ASN1_OBJECT(out, pci->proxyPolicy->policyLanguage);
BIO_puts(out, "\n");
if (pci->proxyPolicy->policy && pci->proxyPolicy->policy->data)
- BIO_printf(out, "%*sPolicy Text: %.*s\n", indent, "",
- pci->proxyPolicy->policy->length,
+ BIO_printf(out, "%*sPolicy Text: %.*s\n", indent, "",
+ pci->proxyPolicy->policy->length,
pci->proxyPolicy->policy->data);
return 1;
}
diff --git a/contrib/libs/openssl/crypto/x509v3/v3_purp.c b/contrib/libs/openssl/crypto/x509v3/v3_purp.c
index fd42bd6b63..a1aeb4e4c6 100644
--- a/contrib/libs/openssl/crypto/x509v3/v3_purp.c
+++ b/contrib/libs/openssl/crypto/x509v3/v3_purp.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -13,7 +13,7 @@
#include <openssl/x509v3.h>
#include <openssl/x509_vfy.h>
#include "crypto/x509.h"
-#include "../x509/x509_local.h" /* for x509_signing_allowed() */
+#include "../x509/x509_local.h" /* for x509_signing_allowed() */
#include "internal/tsan_assist.h"
static void x509v3_cache_extensions(X509 *x);
@@ -345,24 +345,24 @@ static int setup_crldp(X509 *x)
return 1;
}
-/* Check that issuer public key algorithm matches subject signature algorithm */
-static int check_sig_alg_match(const EVP_PKEY *pkey, const X509 *subject)
-{
- int pkey_sig_nid, subj_sig_nid;
-
- if (pkey == NULL)
- return X509_V_ERR_NO_ISSUER_PUBLIC_KEY;
- if (OBJ_find_sigid_algs(EVP_PKEY_base_id(pkey),
- NULL, &pkey_sig_nid) == 0)
- pkey_sig_nid = EVP_PKEY_base_id(pkey);
- if (OBJ_find_sigid_algs(OBJ_obj2nid(subject->cert_info.signature.algorithm),
- NULL, &subj_sig_nid) == 0)
- return X509_V_ERR_UNSUPPORTED_SIGNATURE_ALGORITHM;
- if (pkey_sig_nid != EVP_PKEY_type(subj_sig_nid))
- return X509_V_ERR_SIGNATURE_ALGORITHM_MISMATCH;
- return X509_V_OK;
-}
-
+/* Check that issuer public key algorithm matches subject signature algorithm */
+static int check_sig_alg_match(const EVP_PKEY *pkey, const X509 *subject)
+{
+ int pkey_sig_nid, subj_sig_nid;
+
+ if (pkey == NULL)
+ return X509_V_ERR_NO_ISSUER_PUBLIC_KEY;
+ if (OBJ_find_sigid_algs(EVP_PKEY_base_id(pkey),
+ NULL, &pkey_sig_nid) == 0)
+ pkey_sig_nid = EVP_PKEY_base_id(pkey);
+ if (OBJ_find_sigid_algs(OBJ_obj2nid(subject->cert_info.signature.algorithm),
+ NULL, &subj_sig_nid) == 0)
+ return X509_V_ERR_UNSUPPORTED_SIGNATURE_ALGORITHM;
+ if (pkey_sig_nid != EVP_PKEY_type(subj_sig_nid))
+ return X509_V_ERR_SIGNATURE_ALGORITHM_MISMATCH;
+ return X509_V_OK;
+}
+
#define V1_ROOT (EXFLAG_V1|EXFLAG_SS)
#define ku_reject(x, usage) \
(((x)->ex_flags & EXFLAG_KUSAGE) && !((x)->ex_kusage & (usage)))
@@ -394,8 +394,8 @@ static void x509v3_cache_extensions(X509 *x)
}
if (!X509_digest(x, EVP_sha1(), x->sha1_hash, NULL))
- x->ex_flags |= (EXFLAG_NO_FINGERPRINT | EXFLAG_INVALID);
-
+ x->ex_flags |= (EXFLAG_NO_FINGERPRINT | EXFLAG_INVALID);
+
/* V1 should mean no extensions ... */
if (!X509_get_version(x))
x->ex_flags |= EXFLAG_V1;
@@ -516,11 +516,11 @@ static void x509v3_cache_extensions(X509 *x)
x->ex_flags |= EXFLAG_INVALID;
/* Does subject name match issuer ? */
if (!X509_NAME_cmp(X509_get_subject_name(x), X509_get_issuer_name(x))) {
- x->ex_flags |= EXFLAG_SI; /* cert is self-issued */
- if (X509_check_akid(x, x->akid) == X509_V_OK /* SKID matches AKID */
- /* .. and the signature alg matches the PUBKEY alg: */
- && check_sig_alg_match(X509_get0_pubkey(x), x) == X509_V_OK)
- x->ex_flags |= EXFLAG_SS; /* indicate self-signed */
+ x->ex_flags |= EXFLAG_SI; /* cert is self-issued */
+ if (X509_check_akid(x, x->akid) == X509_V_OK /* SKID matches AKID */
+ /* .. and the signature alg matches the PUBKEY alg: */
+ && check_sig_alg_match(X509_get0_pubkey(x), x) == X509_V_OK)
+ x->ex_flags |= EXFLAG_SS; /* indicate self-signed */
}
x->altname = X509_get_ext_d2i(x, NID_subject_alt_name, &i, NULL);
if (x->altname == NULL && i != -1)
@@ -813,23 +813,23 @@ static int no_check(const X509_PURPOSE *xp, const X509 *x, int ca)
}
/*-
- * Check if certificate I<issuer> is allowed to issue certificate I<subject>
- * according to the B<keyUsage> field of I<issuer> if present
- * depending on any proxyCertInfo extension of I<subject>.
- * Returns 0 for OK, or positive for reason for rejection
- * where reason codes match those for X509_verify_cert().
- */
-int x509_signing_allowed(const X509 *issuer, const X509 *subject)
-{
- if (subject->ex_flags & EXFLAG_PROXY) {
- if (ku_reject(issuer, KU_DIGITAL_SIGNATURE))
- return X509_V_ERR_KEYUSAGE_NO_DIGITAL_SIGNATURE;
- } else if (ku_reject(issuer, KU_KEY_CERT_SIGN))
- return X509_V_ERR_KEYUSAGE_NO_CERTSIGN;
- return X509_V_OK;
-}
-
-/*-
+ * Check if certificate I<issuer> is allowed to issue certificate I<subject>
+ * according to the B<keyUsage> field of I<issuer> if present
+ * depending on any proxyCertInfo extension of I<subject>.
+ * Returns 0 for OK, or positive for reason for rejection
+ * where reason codes match those for X509_verify_cert().
+ */
+int x509_signing_allowed(const X509 *issuer, const X509 *subject)
+{
+ if (subject->ex_flags & EXFLAG_PROXY) {
+ if (ku_reject(issuer, KU_DIGITAL_SIGNATURE))
+ return X509_V_ERR_KEYUSAGE_NO_DIGITAL_SIGNATURE;
+ } else if (ku_reject(issuer, KU_KEY_CERT_SIGN))
+ return X509_V_ERR_KEYUSAGE_NO_CERTSIGN;
+ return X509_V_OK;
+}
+
+/*-
* Various checks to see if one certificate issued the second.
* This can be used to prune a set of possible issuer certificates
* which have been looked up using some simple method such as by
@@ -837,24 +837,24 @@ int x509_signing_allowed(const X509 *issuer, const X509 *subject)
* These are:
* 1. Check issuer_name(subject) == subject_name(issuer)
* 2. If akid(subject) exists check it matches issuer
- * 3. Check that issuer public key algorithm matches subject signature algorithm
- * 4. If key_usage(issuer) exists check it supports certificate signing
+ * 3. Check that issuer public key algorithm matches subject signature algorithm
+ * 4. If key_usage(issuer) exists check it supports certificate signing
* returns 0 for OK, positive for reason for mismatch, reasons match
* codes for X509_verify_cert()
*/
int X509_check_issued(X509 *issuer, X509 *subject)
{
- int ret;
-
- if ((ret = x509_likely_issued(issuer, subject)) != X509_V_OK)
- return ret;
- return x509_signing_allowed(issuer, subject);
-}
-
-/* do the checks 1., 2., and 3. as described above for X509_check_issued() */
-int x509_likely_issued(X509 *issuer, X509 *subject)
-{
+ int ret;
+
+ if ((ret = x509_likely_issued(issuer, subject)) != X509_V_OK)
+ return ret;
+ return x509_signing_allowed(issuer, subject);
+}
+
+/* do the checks 1., 2., and 3. as described above for X509_check_issued() */
+int x509_likely_issued(X509 *issuer, X509 *subject)
+{
if (X509_NAME_cmp(X509_get_subject_name(issuer),
X509_get_issuer_name(subject)))
return X509_V_ERR_SUBJECT_ISSUER_MISMATCH;
@@ -872,8 +872,8 @@ int x509_likely_issued(X509 *issuer, X509 *subject)
return ret;
}
- /* check if the subject signature alg matches the issuer's PUBKEY alg */
- return check_sig_alg_match(X509_get0_pubkey(issuer), subject);
+ /* check if the subject signature alg matches the issuer's PUBKEY alg */
+ return check_sig_alg_match(X509_get0_pubkey(issuer), subject);
}
int X509_check_akid(X509 *issuer, AUTHORITY_KEYID *akid)
diff --git a/contrib/libs/openssl/crypto/x509v3/v3_utl.c b/contrib/libs/openssl/crypto/x509v3/v3_utl.c
index 421cb3a6f4..f41c699b5a 100644
--- a/contrib/libs/openssl/crypto/x509v3/v3_utl.c
+++ b/contrib/libs/openssl/crypto/x509v3/v3_utl.c
@@ -1,5 +1,5 @@
/*
- * Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1999-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -12,7 +12,7 @@
#include "e_os.h"
#include "internal/cryptlib.h"
#include <stdio.h>
-#include <string.h>
+#include <string.h>
#include "crypto/ctype.h"
#include <openssl/conf.h>
#include <openssl/crypto.h>
@@ -35,26 +35,26 @@ static int ipv6_hex(unsigned char *out, const char *in, int inlen);
/* Add a CONF_VALUE name value pair to stack */
-static int x509v3_add_len_value(const char *name, const char *value,
- size_t vallen, STACK_OF(CONF_VALUE) **extlist)
+static int x509v3_add_len_value(const char *name, const char *value,
+ size_t vallen, STACK_OF(CONF_VALUE) **extlist)
{
CONF_VALUE *vtmp = NULL;
char *tname = NULL, *tvalue = NULL;
int sk_allocated = (*extlist == NULL);
- if (name != NULL && (tname = OPENSSL_strdup(name)) == NULL)
+ if (name != NULL && (tname = OPENSSL_strdup(name)) == NULL)
goto err;
- if (value != NULL && vallen > 0) {
- /*
- * We tolerate a single trailing NUL character, but otherwise no
- * embedded NULs
- */
- if (memchr(value, 0, vallen - 1) != NULL)
- goto err;
- tvalue = OPENSSL_strndup(value, vallen);
- if (tvalue == NULL)
- goto err;
- }
+ if (value != NULL && vallen > 0) {
+ /*
+ * We tolerate a single trailing NUL character, but otherwise no
+ * embedded NULs
+ */
+ if (memchr(value, 0, vallen - 1) != NULL)
+ goto err;
+ tvalue = OPENSSL_strndup(value, vallen);
+ if (tvalue == NULL)
+ goto err;
+ }
if ((vtmp = OPENSSL_malloc(sizeof(*vtmp))) == NULL)
goto err;
if (sk_allocated && (*extlist = sk_CONF_VALUE_new_null()) == NULL)
@@ -66,7 +66,7 @@ static int x509v3_add_len_value(const char *name, const char *value,
goto err;
return 1;
err:
- X509V3err(X509V3_F_X509V3_ADD_LEN_VALUE, ERR_R_MALLOC_FAILURE);
+ X509V3err(X509V3_F_X509V3_ADD_LEN_VALUE, ERR_R_MALLOC_FAILURE);
if (sk_allocated) {
sk_CONF_VALUE_free(*extlist);
*extlist = NULL;
@@ -77,28 +77,28 @@ static int x509v3_add_len_value(const char *name, const char *value,
return 0;
}
-int X509V3_add_value(const char *name, const char *value,
- STACK_OF(CONF_VALUE) **extlist)
-{
- return x509v3_add_len_value(name, value,
- value != NULL ? strlen((const char *)value) : 0,
- extlist);
-}
-
+int X509V3_add_value(const char *name, const char *value,
+ STACK_OF(CONF_VALUE) **extlist)
+{
+ return x509v3_add_len_value(name, value,
+ value != NULL ? strlen((const char *)value) : 0,
+ extlist);
+}
+
int X509V3_add_value_uchar(const char *name, const unsigned char *value,
STACK_OF(CONF_VALUE) **extlist)
{
- return x509v3_add_len_value(name, (const char *)value,
- value != NULL ? strlen((const char *)value) : 0,
- extlist);
+ return x509v3_add_len_value(name, (const char *)value,
+ value != NULL ? strlen((const char *)value) : 0,
+ extlist);
+}
+
+int x509v3_add_len_value_uchar(const char *name, const unsigned char *value,
+ size_t vallen, STACK_OF(CONF_VALUE) **extlist)
+{
+ return x509v3_add_len_value(name, (const char *)value, vallen, extlist);
}
-int x509v3_add_len_value_uchar(const char *name, const unsigned char *value,
- size_t vallen, STACK_OF(CONF_VALUE) **extlist)
-{
- return x509v3_add_len_value(name, (const char *)value, vallen, extlist);
-}
-
/* Free function for STACK_OF(CONF_VALUE) */
void X509V3_conf_free(CONF_VALUE *conf)
@@ -528,26 +528,26 @@ static int append_ia5(STACK_OF(OPENSSL_STRING) **sk, const ASN1_IA5STRING *email
/* First some sanity checks */
if (email->type != V_ASN1_IA5STRING)
return 1;
- if (email->data == NULL || email->length == 0)
+ if (email->data == NULL || email->length == 0)
+ return 1;
+ if (memchr(email->data, 0, email->length) != NULL)
return 1;
- if (memchr(email->data, 0, email->length) != NULL)
- return 1;
if (*sk == NULL)
*sk = sk_OPENSSL_STRING_new(sk_strcmp);
if (*sk == NULL)
return 0;
-
- emtmp = OPENSSL_strndup((char *)email->data, email->length);
- if (emtmp == NULL)
- return 0;
-
+
+ emtmp = OPENSSL_strndup((char *)email->data, email->length);
+ if (emtmp == NULL)
+ return 0;
+
/* Don't add duplicates */
- if (sk_OPENSSL_STRING_find(*sk, emtmp) != -1) {
- OPENSSL_free(emtmp);
+ if (sk_OPENSSL_STRING_find(*sk, emtmp) != -1) {
+ OPENSSL_free(emtmp);
return 1;
- }
- if (!sk_OPENSSL_STRING_push(*sk, emtmp)) {
- OPENSSL_free(emtmp); /* free on push failure */
+ }
+ if (!sk_OPENSSL_STRING_push(*sk, emtmp)) {
+ OPENSSL_free(emtmp); /* free on push failure */
X509_email_free(*sk);
*sk = NULL;
return 0;
diff --git a/contrib/libs/openssl/crypto/x509v3/v3err.c b/contrib/libs/openssl/crypto/x509v3/v3err.c
index ce9770aea3..8b2918a64f 100644
--- a/contrib/libs/openssl/crypto/x509v3/v3err.c
+++ b/contrib/libs/openssl/crypto/x509v3/v3err.c
@@ -1,6 +1,6 @@
/*
* Generated by util/mkerr.pl DO NOT EDIT
- * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
*
* Licensed under the OpenSSL license (the "License"). You may not use
* this file except in compliance with the License. You can obtain a copy
@@ -39,8 +39,8 @@ static const ERR_STRING_DATA X509V3_str_functs[] = {
"i2s_ASN1_INTEGER"},
{ERR_PACK(ERR_LIB_X509V3, X509V3_F_I2V_AUTHORITY_INFO_ACCESS, 0),
"i2v_AUTHORITY_INFO_ACCESS"},
- {ERR_PACK(ERR_LIB_X509V3, X509V3_F_I2V_AUTHORITY_KEYID, 0),
- "i2v_AUTHORITY_KEYID"},
+ {ERR_PACK(ERR_LIB_X509V3, X509V3_F_I2V_AUTHORITY_KEYID, 0),
+ "i2v_AUTHORITY_KEYID"},
{ERR_PACK(ERR_LIB_X509V3, X509V3_F_LEVEL_ADD_NODE, 0), "level_add_node"},
{ERR_PACK(ERR_LIB_X509V3, X509V3_F_NOTICE_SECTION, 0), "notice_section"},
{ERR_PACK(ERR_LIB_X509V3, X509V3_F_NREF_NOS, 0), "nref_nos"},
@@ -106,8 +106,8 @@ static const ERR_STRING_DATA X509V3_str_functs[] = {
{ERR_PACK(ERR_LIB_X509V3, X509V3_F_V3_GENERIC_EXTENSION, 0),
"v3_generic_extension"},
{ERR_PACK(ERR_LIB_X509V3, X509V3_F_X509V3_ADD1_I2D, 0), "X509V3_add1_i2d"},
- {ERR_PACK(ERR_LIB_X509V3, X509V3_F_X509V3_ADD_LEN_VALUE, 0),
- "x509v3_add_len_value"},
+ {ERR_PACK(ERR_LIB_X509V3, X509V3_F_X509V3_ADD_LEN_VALUE, 0),
+ "x509v3_add_len_value"},
{ERR_PACK(ERR_LIB_X509V3, X509V3_F_X509V3_ADD_VALUE, 0),
"X509V3_add_value"},
{ERR_PACK(ERR_LIB_X509V3, X509V3_F_X509V3_EXT_ADD, 0), "X509V3_EXT_add"},
diff --git a/contrib/libs/openssl/crypto/ya.make b/contrib/libs/openssl/crypto/ya.make
index 4518ced107..3acfb0cac7 100644
--- a/contrib/libs/openssl/crypto/ya.make
+++ b/contrib/libs/openssl/crypto/ya.make
@@ -1,23 +1,23 @@
LIBRARY()
-LICENSE(
- Apache-2.0 AND
- BSD-2-Clause AND
- BSD-3-Clause AND
- BSD-Source-Code AND
- CC0-1.0 AND
- OpenSSL AND
- Public-Domain AND
- Snprintf
-)
+LICENSE(
+ Apache-2.0 AND
+ BSD-2-Clause AND
+ BSD-3-Clause AND
+ BSD-Source-Code AND
+ CC0-1.0 AND
+ OpenSSL AND
+ Public-Domain AND
+ Snprintf
+)
+
+LICENSE_TEXTS(.yandex_meta/licenses.list.txt)
-LICENSE_TEXTS(.yandex_meta/licenses.list.txt)
+OWNER(
+ somov
+ g:cpp-contrib
+)
-OWNER(
- somov
- g:cpp-contrib
-)
-
PEERDIR(
contrib/libs/zlib
)
@@ -34,41 +34,41 @@ ADDINCL(
IF (OS_LINUX)
IF (ARCH_ARM64)
SET(LINUX_ARM64 yes)
- ELSEIF (ARCH_ARM7)
+ ELSEIF (ARCH_ARM7)
SET(LINUX_ARMV7 yes)
- ELSEIF (ARCH_X86_64)
+ ELSEIF (ARCH_X86_64)
SET(LINUX_X86_64 yes)
ENDIF()
ENDIF()
-IF (OS_IOS)
- IF (ARCH_ARM64)
- SET(IOS_ARM64 yes)
- ELSEIF (ARCH_ARM7)
- SET(IOS_ARMV7 yes)
- ELSEIF (ARCH_X86_64)
- SET(IOS_X86_64 yes)
- ELSEIF (ARCH_I386)
- SET(IOS_I386 yes)
- ENDIF()
-ENDIF()
-
-IF (OS_ANDROID)
- IF (ARCH_ARM64)
- SET(ANDROID_ARM64 yes)
- ELSEIF (ARCH_ARM7)
- SET(ANDROID_ARMV7 yes)
- ELSEIF (ARCH_X86_64)
- SET(ANDROID_X86_64 yes)
- ELSEIF (ARCH_I686)
- SET(ANDROID_I686 yes)
- ENDIF()
-ENDIF()
-
+IF (OS_IOS)
+ IF (ARCH_ARM64)
+ SET(IOS_ARM64 yes)
+ ELSEIF (ARCH_ARM7)
+ SET(IOS_ARMV7 yes)
+ ELSEIF (ARCH_X86_64)
+ SET(IOS_X86_64 yes)
+ ELSEIF (ARCH_I386)
+ SET(IOS_I386 yes)
+ ENDIF()
+ENDIF()
+
+IF (OS_ANDROID)
+ IF (ARCH_ARM64)
+ SET(ANDROID_ARM64 yes)
+ ELSEIF (ARCH_ARM7)
+ SET(ANDROID_ARMV7 yes)
+ ELSEIF (ARCH_X86_64)
+ SET(ANDROID_X86_64 yes)
+ ELSEIF (ARCH_I686)
+ SET(ANDROID_I686 yes)
+ ENDIF()
+ENDIF()
+
IF (OS_WINDOWS)
IF (ARCH_X86_64)
SET(WINDOWS_X86_64 yes)
- ELSEIF (ARCH_I686)
+ ELSEIF (ARCH_I686)
SET(WINDOWS_I686 yes)
ENDIF()
ENDIF()
@@ -98,24 +98,24 @@ IF (NOT IOS_ARM64 AND NOT DARWIN_ARM64)
ENDIF()
IF (NOT WINDOWS_I686)
- CFLAGS(
+ CFLAGS(
-DECP_NISTZ256_ASM
-DPOLY1305_ASM
)
ENDIF()
IF (NOT IOS_I386 AND NOT ANDROID_I686 AND NOT WINDOWS_I686)
- CFLAGS(
- -DKECCAK1600_ASM
- )
-ENDIF()
-
+ CFLAGS(
+ -DKECCAK1600_ASM
+ )
+ENDIF()
+
IF (NOT IOS_ARMV7 AND NOT ANDROID_ARMV7 AND NOT LINUX_ARMV7)
- CFLAGS(
- -DVPAES_ASM
- )
-ENDIF()
-
+ CFLAGS(
+ -DVPAES_ASM
+ )
+ENDIF()
+
IF (NOT OS_WINDOWS)
CFLAGS(
-DENGINESDIR=\"/usr/local/lib/engines-1.1\"
@@ -137,32 +137,32 @@ IF (OS_DARWIN AND ARCH_X86_64 OR OS_LINUX AND ARCH_X86_64 OR OS_WINDOWS AND ARCH
ENDIF()
IF (OS_LINUX AND ARCH_AARCH64 OR OS_LINUX AND ARCH_X86_64)
- CFLAGS(
- -DOPENSSL_USE_NODELETE
- )
+ CFLAGS(
+ -DOPENSSL_USE_NODELETE
+ )
ENDIF()
IF (OS_DARWIN AND ARCH_X86_64)
- CFLAGS(
- -D_REENTRANT
- )
+ CFLAGS(
+ -D_REENTRANT
+ )
+ENDIF()
+
+IF (OS_DARWIN AND ARCH_ARM64)
+ CFLAGS(
+ -DL_ENDIAN
+ -DOPENSSL_PIC
+ -D_REENTRANT
+ )
ENDIF()
-IF (OS_DARWIN AND ARCH_ARM64)
- CFLAGS(
- -DL_ENDIAN
- -DOPENSSL_PIC
- -D_REENTRANT
- )
-ENDIF()
-
IF (OS_WINDOWS)
IF (ARCH_X86_64)
CFLAGS(
-DENGINESDIR="\"C:\\\\Program\ Files\\\\OpenSSL\\\\lib\\\\engines-1_1\""
-DOPENSSLDIR="\"C:\\\\Program\ Files\\\\Common\ Files\\\\SSL\""
)
- ELSEIF (ARCH_I386)
+ ELSEIF (ARCH_I386)
CFLAGS(
-DENGINESDIR="\"C:\\\\Program\ Files\ \(x86\)\\\\OpenSSL\\\\lib\\\\engines-1_1\""
-DOPENSSLDIR="\"C:\\\\Program\ Files\ \(x86\)\\\\Common\ Files\\\\SSL\""
@@ -180,33 +180,33 @@ IF (OS_WINDOWS)
ENDIF()
IF (SANITIZER_TYPE == memory)
- CFLAGS(
- -DPURIFY
- )
+ CFLAGS(
+ -DPURIFY
+ )
ENDIF()
IF (MUSL)
- CFLAGS(
- -DOPENSSL_NO_ASYNC
- )
+ CFLAGS(
+ -DOPENSSL_NO_ASYNC
+ )
ENDIF()
IF (ARCH_TYPE_32)
- CFLAGS(
- -DOPENSSL_NO_EC_NISTP_64_GCC_128
- )
+ CFLAGS(
+ -DOPENSSL_NO_EC_NISTP_64_GCC_128
+ )
ENDIF()
IF (ARCH_X86_64 AND NOT MSVC)
- SET_APPEND(
- SFLAGS
- -mavx512bw
- -mavx512ifma
- -mavx512vl
- )
+ SET_APPEND(
+ SFLAGS
+ -mavx512bw
+ -mavx512ifma
+ -mavx512vl
+ )
ENDIF()
-IF (OS_WINDOWS)
+IF (OS_WINDOWS)
SET_COMPILE_OUTPUTS_MODIFIERS(NOREL)
ENDIF()
@@ -818,48 +818,48 @@ IF (NOT WINDOWS_I686)
)
ENDIF()
-IF (NOT IOS_ARM64 AND NOT IOS_ARMV7)
- SRCS(
- engine/eng_all.c
- engine/eng_cnf.c
- engine/eng_ctrl.c
- engine/eng_dyn.c
- engine/eng_err.c
- engine/eng_fat.c
- engine/eng_init.c
- engine/eng_lib.c
- engine/eng_list.c
- engine/eng_openssl.c
- engine/eng_pkey.c
- engine/eng_rdrand.c
- engine/eng_table.c
- engine/tb_asnmth.c
- engine/tb_cipher.c
- engine/tb_dh.c
- engine/tb_digest.c
- engine/tb_dsa.c
- engine/tb_eckey.c
- engine/tb_pkmeth.c
- engine/tb_rand.c
- engine/tb_rsa.c
- )
-ENDIF()
-
+IF (NOT IOS_ARM64 AND NOT IOS_ARMV7)
+ SRCS(
+ engine/eng_all.c
+ engine/eng_cnf.c
+ engine/eng_ctrl.c
+ engine/eng_dyn.c
+ engine/eng_err.c
+ engine/eng_fat.c
+ engine/eng_init.c
+ engine/eng_lib.c
+ engine/eng_list.c
+ engine/eng_openssl.c
+ engine/eng_pkey.c
+ engine/eng_rdrand.c
+ engine/eng_table.c
+ engine/tb_asnmth.c
+ engine/tb_cipher.c
+ engine/tb_dh.c
+ engine/tb_digest.c
+ engine/tb_dsa.c
+ engine/tb_eckey.c
+ engine/tb_pkmeth.c
+ engine/tb_rand.c
+ engine/tb_rsa.c
+ )
+ENDIF()
+
IF (NOT IOS_ARMV7 AND NOT ANDROID_ARMV7 AND NOT LINUX_ARMV7)
- SRCS(
- aes/aes_core.c
- )
-ENDIF()
-
+ SRCS(
+ aes/aes_core.c
+ )
+ENDIF()
+
IF (NOT IOS_I386 AND NOT ANDROID_I686 AND NOT WINDOWS_I686)
- SRCS(
- bf/bf_enc.c
- camellia/cmll_misc.c
- des/des_enc.c
- des/fcrypt_b.c
- )
-ENDIF()
-
+ SRCS(
+ bf/bf_enc.c
+ camellia/cmll_misc.c
+ des/des_enc.c
+ des/fcrypt_b.c
+ )
+ENDIF()
+
IF (OS_DARWIN AND ARCH_X86_64 OR OS_LINUX AND ARCH_X86_64 OR OS_WINDOWS AND ARCH_X86_64)
SRCS(
bn/rsaz_exp.c
@@ -911,39 +911,39 @@ IF (OS_DARWIN AND ARCH_X86_64)
)
ENDIF()
-IF (OS_DARWIN AND ARCH_ARM64)
- SRCS(
- ../asm/darwin-arm64/crypto/sha/keccak1600-armv8.S
- ../asm/darwin-arm64/crypto/sha/sha512-armv8.S
- ../asm/darwin-arm64/crypto/sha/sha1-armv8.S
- ../asm/darwin-arm64/crypto/sha/sha256-armv8.S
- ../asm/darwin-arm64/crypto/poly1305/poly1305-armv8.S
- ../asm/darwin-arm64/crypto/ec/ecp_nistz256-armv8.S
- ../asm/darwin-arm64/crypto/chacha/chacha-armv8.S
- ../asm/darwin-arm64/crypto/bn/armv8-mont.S
- ../asm/darwin-arm64/crypto/arm64cpuid.S
- ../asm/darwin-arm64/crypto/aes/aesv8-armx.S
- ../asm/darwin-arm64/crypto/aes/vpaes-armv8.S
- ../asm/darwin-arm64/crypto/modes/ghashv8-armx.S
- armcap.c
- bn/bn_asm.c
- camellia/camellia.c
- camellia/cmll_cbc.c
+IF (OS_DARWIN AND ARCH_ARM64)
+ SRCS(
+ ../asm/darwin-arm64/crypto/sha/keccak1600-armv8.S
+ ../asm/darwin-arm64/crypto/sha/sha512-armv8.S
+ ../asm/darwin-arm64/crypto/sha/sha1-armv8.S
+ ../asm/darwin-arm64/crypto/sha/sha256-armv8.S
+ ../asm/darwin-arm64/crypto/poly1305/poly1305-armv8.S
+ ../asm/darwin-arm64/crypto/ec/ecp_nistz256-armv8.S
+ ../asm/darwin-arm64/crypto/chacha/chacha-armv8.S
+ ../asm/darwin-arm64/crypto/bn/armv8-mont.S
+ ../asm/darwin-arm64/crypto/arm64cpuid.S
+ ../asm/darwin-arm64/crypto/aes/aesv8-armx.S
+ ../asm/darwin-arm64/crypto/aes/vpaes-armv8.S
+ ../asm/darwin-arm64/crypto/modes/ghashv8-armx.S
+ armcap.c
+ bn/bn_asm.c
+ camellia/camellia.c
+ camellia/cmll_cbc.c
dso/dso_dlfcn.c
- rc4/rc4_enc.c
- rc4/rc4_skey.c
- whrlpool/wp_block.c
- )
-ENDIF()
-
+ rc4/rc4_enc.c
+ rc4/rc4_skey.c
+ whrlpool/wp_block.c
+ )
+ENDIF()
+
IF (OS_LINUX AND ARCH_ARM7)
IF (CLANG)
# XXX: This is a workarond for 'out of range immediate fixup value'
# error with clang integrated assembler:
# https://github.com/openssl/openssl/issues/7878
- CFLAGS(
- -mno-thumb
- )
+ CFLAGS(
+ -mno-thumb
+ )
ENDIF()
CFLAGS(
-DOPENSSL_PIC
@@ -1066,35 +1066,35 @@ ENDIF()
IF (OS_WINDOWS AND ARCH_X86_64)
SRCS(
- ../asm/windows/crypto/aes/aesni-mb-x86_64.masm
- ../asm/windows/crypto/aes/aesni-sha1-x86_64.masm
- ../asm/windows/crypto/aes/aesni-sha256-x86_64.masm
- ../asm/windows/crypto/aes/aesni-x86_64.masm
- ../asm/windows/crypto/aes/vpaes-x86_64.masm
- ../asm/windows/crypto/bn/rsaz-avx2.masm
- ../asm/windows/crypto/bn/rsaz-x86_64.masm
- ../asm/windows/crypto/bn/x86_64-gf2m.masm
- ../asm/windows/crypto/bn/x86_64-mont.masm
- ../asm/windows/crypto/bn/x86_64-mont5.masm
- ../asm/windows/crypto/camellia/cmll-x86_64.masm
- ../asm/windows/crypto/chacha/chacha-x86_64.masm
- ../asm/windows/crypto/ec/ecp_nistz256-x86_64.masm
- ../asm/windows/crypto/ec/x25519-x86_64.masm
- ../asm/windows/crypto/md5/md5-x86_64.masm
- ../asm/windows/crypto/modes/aesni-gcm-x86_64.masm
- ../asm/windows/crypto/modes/ghash-x86_64.masm
- ../asm/windows/crypto/poly1305/poly1305-x86_64.masm
- ../asm/windows/crypto/rc4/rc4-md5-x86_64.masm
- ../asm/windows/crypto/rc4/rc4-x86_64.masm
- ../asm/windows/crypto/sha/keccak1600-x86_64.masm
- ../asm/windows/crypto/sha/sha1-mb-x86_64.masm
- ../asm/windows/crypto/sha/sha1-x86_64.masm
- ../asm/windows/crypto/sha/sha256-mb-x86_64.masm
- ../asm/windows/crypto/sha/sha256-x86_64.masm
- ../asm/windows/crypto/sha/sha512-x86_64.masm
- ../asm/windows/crypto/whrlpool/wp-x86_64.masm
- ../asm/windows/crypto/uplink-x86_64.masm
- ../asm/windows/crypto/x86_64cpuid.masm
+ ../asm/windows/crypto/aes/aesni-mb-x86_64.masm
+ ../asm/windows/crypto/aes/aesni-sha1-x86_64.masm
+ ../asm/windows/crypto/aes/aesni-sha256-x86_64.masm
+ ../asm/windows/crypto/aes/aesni-x86_64.masm
+ ../asm/windows/crypto/aes/vpaes-x86_64.masm
+ ../asm/windows/crypto/bn/rsaz-avx2.masm
+ ../asm/windows/crypto/bn/rsaz-x86_64.masm
+ ../asm/windows/crypto/bn/x86_64-gf2m.masm
+ ../asm/windows/crypto/bn/x86_64-mont.masm
+ ../asm/windows/crypto/bn/x86_64-mont5.masm
+ ../asm/windows/crypto/camellia/cmll-x86_64.masm
+ ../asm/windows/crypto/chacha/chacha-x86_64.masm
+ ../asm/windows/crypto/ec/ecp_nistz256-x86_64.masm
+ ../asm/windows/crypto/ec/x25519-x86_64.masm
+ ../asm/windows/crypto/md5/md5-x86_64.masm
+ ../asm/windows/crypto/modes/aesni-gcm-x86_64.masm
+ ../asm/windows/crypto/modes/ghash-x86_64.masm
+ ../asm/windows/crypto/poly1305/poly1305-x86_64.masm
+ ../asm/windows/crypto/rc4/rc4-md5-x86_64.masm
+ ../asm/windows/crypto/rc4/rc4-x86_64.masm
+ ../asm/windows/crypto/sha/keccak1600-x86_64.masm
+ ../asm/windows/crypto/sha/sha1-mb-x86_64.masm
+ ../asm/windows/crypto/sha/sha1-x86_64.masm
+ ../asm/windows/crypto/sha/sha256-mb-x86_64.masm
+ ../asm/windows/crypto/sha/sha256-x86_64.masm
+ ../asm/windows/crypto/sha/sha512-x86_64.masm
+ ../asm/windows/crypto/whrlpool/wp-x86_64.masm
+ ../asm/windows/crypto/uplink-x86_64.masm
+ ../asm/windows/crypto/x86_64cpuid.masm
)
ENDIF()
@@ -1128,329 +1128,329 @@ IF (OS_WINDOWS AND ARCH_I386)
)
ENDIF()
-IF (OS_IOS AND ARCH_ARM64)
- CFLAGS(
- -DOPENSSL_PIC
- -D_REENTRANT
- )
- SRCS(
- ../asm/ios/arm64/crypto/aes/aesv8-armx.S
- ../asm/ios/arm64/crypto/aes/vpaes-armv8.S
- ../asm/ios/arm64/crypto/arm64cpuid.S
- ../asm/ios/arm64/crypto/bn/armv8-mont.S
- ../asm/ios/arm64/crypto/chacha/chacha-armv8.S
- ../asm/ios/arm64/crypto/ec/ecp_nistz256-armv8.S
- ../asm/ios/arm64/crypto/modes/ghashv8-armx.S
- ../asm/ios/arm64/crypto/poly1305/poly1305-armv8.S
- ../asm/ios/arm64/crypto/sha/keccak1600-armv8.S
- ../asm/ios/arm64/crypto/sha/sha1-armv8.S
- ../asm/ios/arm64/crypto/sha/sha256-armv8.S
- ../asm/ios/arm64/crypto/sha/sha512-armv8.S
- armcap.c
- bn/bn_asm.c
- camellia/camellia.c
- camellia/cmll_cbc.c
- dso/dso_dlfcn.c
- rand/rand_vms.c
- rc4/rc4_enc.c
- rc4/rc4_skey.c
- whrlpool/wp_block.c
- )
-ENDIF()
-
-IF (OS_IOS AND ARCH_ARM7)
- CFLAGS(
- -DOPENSSL_PIC
- -DOPENSSL_BN_ASM_GF2m
- -DAES_ASM
- -DBSAES_ASM
- -DGHASH_ASM
- -D_REENTRANT
- )
- SRCS(
- ../asm/ios/armv7/crypto/modes/ghash-armv4.S
- ../asm/ios/armv7/crypto/modes/ghashv8-armx.S
- ../asm/ios/armv7/crypto/chacha/chacha-armv4.S
- ../asm/ios/armv7/crypto/ec/ecp_nistz256-armv4.S
- ../asm/ios/armv7/crypto/poly1305/poly1305-armv4.S
- ../asm/ios/armv7/crypto/bn/armv4-gf2m.S
- ../asm/ios/armv7/crypto/bn/armv4-mont.S
- ../asm/ios/armv7/crypto/sha/sha512-armv4.S
- ../asm/ios/armv7/crypto/sha/sha1-armv4-large.S
- ../asm/ios/armv7/crypto/sha/sha256-armv4.S
- ../asm/ios/armv7/crypto/sha/keccak1600-armv4.S
- ../asm/ios/armv7/crypto/armv4cpuid.S
- ../asm/ios/armv7/crypto/aes/aesv8-armx.S
- ../asm/ios/armv7/crypto/aes/bsaes-armv7.S
- ../asm/ios/armv7/crypto/aes/aes-armv4.S
- armcap.c
- bn/bn_asm.c
- camellia/camellia.c
- camellia/cmll_cbc.c
- dso/dso_dlfcn.c
- rand/rand_vms.c
- rc4/rc4_enc.c
- rc4/rc4_skey.c
- whrlpool/wp_block.c
- )
-ENDIF()
-
-IF (OS_IOS AND ARCH_X86_64)
- CFLAGS(
- -DL_ENDIAN
- -DOPENSSL_PIC
- -DOPENSSL_IA32_SSE2
- -DOPENSSL_BN_ASM_MONT5
- -DOPENSSL_BN_ASM_GF2m
- -DRC4_ASM
- -DMD5_ASM
- -DGHASH_ASM
- -DECP_NISTZ256_ASM
- -DX25519_ASM
- -D_REENTRANT
- )
- SRCS(
- ../asm/ios/x86_64/crypto/md5/md5-x86_64.s
- ../asm/ios/x86_64/crypto/rc4/rc4-md5-x86_64.s
- ../asm/ios/x86_64/crypto/rc4/rc4-x86_64.s
- ../asm/ios/x86_64/crypto/modes/ghash-x86_64.s
- ../asm/ios/x86_64/crypto/modes/aesni-gcm-x86_64.s
- ../asm/ios/x86_64/crypto/chacha/chacha-x86_64.s
- ../asm/ios/x86_64/crypto/ec/ecp_nistz256-x86_64.s
- ../asm/ios/x86_64/crypto/ec/x25519-x86_64.s
- ../asm/ios/x86_64/crypto/x86_64cpuid.s
- ../asm/ios/x86_64/crypto/poly1305/poly1305-x86_64.s
- ../asm/ios/x86_64/crypto/bn/rsaz-x86_64.s
- ../asm/ios/x86_64/crypto/bn/x86_64-mont.s
- ../asm/ios/x86_64/crypto/bn/x86_64-gf2m.s
- ../asm/ios/x86_64/crypto/bn/x86_64-mont5.s
- ../asm/ios/x86_64/crypto/bn/rsaz-avx2.s
- ../asm/ios/x86_64/crypto/sha/sha512-x86_64.s
- ../asm/ios/x86_64/crypto/sha/sha256-x86_64.s
- ../asm/ios/x86_64/crypto/sha/keccak1600-x86_64.s
- ../asm/ios/x86_64/crypto/sha/sha1-x86_64.s
- ../asm/ios/x86_64/crypto/sha/sha1-mb-x86_64.s
- ../asm/ios/x86_64/crypto/sha/sha256-mb-x86_64.s
- ../asm/ios/x86_64/crypto/camellia/cmll-x86_64.s
- ../asm/ios/x86_64/crypto/whrlpool/wp-x86_64.s
- ../asm/ios/x86_64/crypto/aes/vpaes-x86_64.s
- ../asm/ios/x86_64/crypto/aes/aesni-sha1-x86_64.s
- ../asm/ios/x86_64/crypto/aes/aesni-sha256-x86_64.s
- ../asm/ios/x86_64/crypto/aes/aesni-x86_64.s
- ../asm/ios/x86_64/crypto/aes/aesni-mb-x86_64.s
- bn/asm/x86_64-gcc.c
- bn/rsaz_exp.c
- dso/dso_dlfcn.c
- rand/rand_vms.c
- )
-ENDIF()
-
-IF (OS_IOS AND ARCH_I386)
- CFLAGS(
- -DL_ENDIAN
- -DOPENSSL_PIC
- -DOPENSSL_BN_ASM_PART_WORDS
- -DOPENSSL_IA32_SSE2
- -DOPENSSL_BN_ASM_GF2m
- -DRC4_ASM
- -DMD5_ASM
- -DRMD160_ASM
- -DWHIRLPOOL_ASM
- -DGHASH_ASM
- -D_REENTRANT
- )
- SRCS(
- ../asm/ios/i386/crypto/md5/md5-586.s
- ../asm/ios/i386/crypto/rc4/rc4-586.s
- ../asm/ios/i386/crypto/des/des-586.s
- ../asm/ios/i386/crypto/des/crypt586.s
- ../asm/ios/i386/crypto/modes/ghash-x86.s
- ../asm/ios/i386/crypto/x86cpuid.s
- ../asm/ios/i386/crypto/chacha/chacha-x86.s
- ../asm/ios/i386/crypto/ec/ecp_nistz256-x86.s
- ../asm/ios/i386/crypto/poly1305/poly1305-x86.s
- ../asm/ios/i386/crypto/bf/bf-586.s
- ../asm/ios/i386/crypto/bn/co-586.s
- ../asm/ios/i386/crypto/bn/x86-mont.s
- ../asm/ios/i386/crypto/bn/x86-gf2m.s
- ../asm/ios/i386/crypto/bn/bn-586.s
- ../asm/ios/i386/crypto/sha/sha512-586.s
- ../asm/ios/i386/crypto/sha/sha1-586.s
- ../asm/ios/i386/crypto/sha/sha256-586.s
- ../asm/ios/i386/crypto/camellia/cmll-x86.s
- ../asm/ios/i386/crypto/whrlpool/wp-mmx.s
- ../asm/ios/i386/crypto/ripemd/rmd-586.s
- ../asm/ios/i386/crypto/aes/vpaes-x86.s
- ../asm/ios/i386/crypto/aes/aesni-x86.s
- ../asm/ios/i386/engines/e_padlock-x86.s
- dso/dso_dlfcn.c
- rand/rand_vms.c
- sha/keccak1600.c
- whrlpool/wp_block.c
- )
-ENDIF()
-
-IF (OS_ANDROID AND ARCH_X86_64)
- CFLAGS(
- -DOPENSSL_USE_NODELETE
- -DOPENSSL_PIC
- -DOPENSSL_IA32_SSE2
- -DOPENSSL_BN_ASM_MONT5
- -DOPENSSL_BN_ASM_GF2m
- -DRC4_ASM
- -DMD5_ASM
- -DGHASH_ASM
- -DX25519_ASM
- )
- SRCS(
- ../asm/android/x86_64/crypto/ec/x25519-x86_64.s
- ../asm/android/x86_64/crypto/ec/ecp_nistz256-x86_64.s
- ../asm/android/x86_64/crypto/md5/md5-x86_64.s
- ../asm/android/x86_64/crypto/rc4/rc4-x86_64.s
- ../asm/android/x86_64/crypto/rc4/rc4-md5-x86_64.s
- ../asm/android/x86_64/crypto/whrlpool/wp-x86_64.s
- ../asm/android/x86_64/crypto/poly1305/poly1305-x86_64.s
- ../asm/android/x86_64/crypto/x86_64cpuid.s
- ../asm/android/x86_64/crypto/camellia/cmll-x86_64.s
- ../asm/android/x86_64/crypto/bn/x86_64-mont5.s
- ../asm/android/x86_64/crypto/bn/rsaz-avx2.s
- ../asm/android/x86_64/crypto/bn/rsaz-x86_64.s
- ../asm/android/x86_64/crypto/bn/x86_64-mont.s
- ../asm/android/x86_64/crypto/bn/x86_64-gf2m.s
- ../asm/android/x86_64/crypto/aes/aesni-sha256-x86_64.s
- ../asm/android/x86_64/crypto/aes/aesni-mb-x86_64.s
- ../asm/android/x86_64/crypto/aes/aesni-x86_64.s
- ../asm/android/x86_64/crypto/aes/vpaes-x86_64.s
- ../asm/android/x86_64/crypto/aes/aesni-sha1-x86_64.s
- ../asm/android/x86_64/crypto/sha/sha256-x86_64.s
- ../asm/android/x86_64/crypto/sha/sha1-mb-x86_64.s
- ../asm/android/x86_64/crypto/sha/sha1-x86_64.s
- ../asm/android/x86_64/crypto/sha/sha256-mb-x86_64.s
- ../asm/android/x86_64/crypto/sha/sha512-x86_64.s
- ../asm/android/x86_64/crypto/sha/keccak1600-x86_64.s
- ../asm/android/x86_64/crypto/chacha/chacha-x86_64.s
- ../asm/android/x86_64/crypto/modes/ghash-x86_64.s
- ../asm/android/x86_64/crypto/modes/aesni-gcm-x86_64.s
- bn/asm/x86_64-gcc.c
- bn/rsaz_exp.c
- dso/dso_dlfcn.c
- rand/rand_vms.c
- )
-ENDIF()
-
-IF (OS_ANDROID AND ARCH_I686)
- CFLAGS(
- -DOPENSSL_PIC
- -DOPENSSL_BN_ASM_PART_WORDS
- -DOPENSSL_IA32_SSE2
- -DOPENSSL_BN_ASM_GF2m
- -DRC4_ASM
- -DMD5_ASM
- -DRMD160_ASM
- -DWHIRLPOOL_ASM
- -DGHASH_ASM
- )
- SRCS(
- ../asm/android/i686/crypto/ec/ecp_nistz256-x86.s
- ../asm/android/i686/crypto/bf/bf-586.s
- ../asm/android/i686/crypto/md5/md5-586.s
- ../asm/android/i686/crypto/rc4/rc4-586.s
- ../asm/android/i686/crypto/whrlpool/wp-mmx.s
- ../asm/android/i686/crypto/x86cpuid.s
- ../asm/android/i686/crypto/des/crypt586.s
- ../asm/android/i686/crypto/des/des-586.s
- ../asm/android/i686/crypto/poly1305/poly1305-x86.s
- ../asm/android/i686/crypto/ripemd/rmd-586.s
- ../asm/android/i686/crypto/camellia/cmll-x86.s
- ../asm/android/i686/crypto/bn/bn-586.s
- ../asm/android/i686/crypto/bn/co-586.s
- ../asm/android/i686/crypto/bn/x86-gf2m.s
- ../asm/android/i686/crypto/bn/x86-mont.s
- ../asm/android/i686/crypto/aes/aesni-x86.s
- ../asm/android/i686/crypto/aes/vpaes-x86.s
- ../asm/android/i686/crypto/sha/sha512-586.s
- ../asm/android/i686/crypto/sha/sha256-586.s
- ../asm/android/i686/crypto/sha/sha1-586.s
- ../asm/android/i686/crypto/chacha/chacha-x86.s
- ../asm/android/i686/crypto/modes/ghash-x86.s
- dso/dso_dlfcn.c
- rand/rand_vms.c
- sha/keccak1600.c
- whrlpool/wp_block.c
- )
-ENDIF()
-
-IF (OS_ANDROID AND ARCH_ARM7)
+IF (OS_IOS AND ARCH_ARM64)
+ CFLAGS(
+ -DOPENSSL_PIC
+ -D_REENTRANT
+ )
+ SRCS(
+ ../asm/ios/arm64/crypto/aes/aesv8-armx.S
+ ../asm/ios/arm64/crypto/aes/vpaes-armv8.S
+ ../asm/ios/arm64/crypto/arm64cpuid.S
+ ../asm/ios/arm64/crypto/bn/armv8-mont.S
+ ../asm/ios/arm64/crypto/chacha/chacha-armv8.S
+ ../asm/ios/arm64/crypto/ec/ecp_nistz256-armv8.S
+ ../asm/ios/arm64/crypto/modes/ghashv8-armx.S
+ ../asm/ios/arm64/crypto/poly1305/poly1305-armv8.S
+ ../asm/ios/arm64/crypto/sha/keccak1600-armv8.S
+ ../asm/ios/arm64/crypto/sha/sha1-armv8.S
+ ../asm/ios/arm64/crypto/sha/sha256-armv8.S
+ ../asm/ios/arm64/crypto/sha/sha512-armv8.S
+ armcap.c
+ bn/bn_asm.c
+ camellia/camellia.c
+ camellia/cmll_cbc.c
+ dso/dso_dlfcn.c
+ rand/rand_vms.c
+ rc4/rc4_enc.c
+ rc4/rc4_skey.c
+ whrlpool/wp_block.c
+ )
+ENDIF()
+
+IF (OS_IOS AND ARCH_ARM7)
+ CFLAGS(
+ -DOPENSSL_PIC
+ -DOPENSSL_BN_ASM_GF2m
+ -DAES_ASM
+ -DBSAES_ASM
+ -DGHASH_ASM
+ -D_REENTRANT
+ )
+ SRCS(
+ ../asm/ios/armv7/crypto/modes/ghash-armv4.S
+ ../asm/ios/armv7/crypto/modes/ghashv8-armx.S
+ ../asm/ios/armv7/crypto/chacha/chacha-armv4.S
+ ../asm/ios/armv7/crypto/ec/ecp_nistz256-armv4.S
+ ../asm/ios/armv7/crypto/poly1305/poly1305-armv4.S
+ ../asm/ios/armv7/crypto/bn/armv4-gf2m.S
+ ../asm/ios/armv7/crypto/bn/armv4-mont.S
+ ../asm/ios/armv7/crypto/sha/sha512-armv4.S
+ ../asm/ios/armv7/crypto/sha/sha1-armv4-large.S
+ ../asm/ios/armv7/crypto/sha/sha256-armv4.S
+ ../asm/ios/armv7/crypto/sha/keccak1600-armv4.S
+ ../asm/ios/armv7/crypto/armv4cpuid.S
+ ../asm/ios/armv7/crypto/aes/aesv8-armx.S
+ ../asm/ios/armv7/crypto/aes/bsaes-armv7.S
+ ../asm/ios/armv7/crypto/aes/aes-armv4.S
+ armcap.c
+ bn/bn_asm.c
+ camellia/camellia.c
+ camellia/cmll_cbc.c
+ dso/dso_dlfcn.c
+ rand/rand_vms.c
+ rc4/rc4_enc.c
+ rc4/rc4_skey.c
+ whrlpool/wp_block.c
+ )
+ENDIF()
+
+IF (OS_IOS AND ARCH_X86_64)
+ CFLAGS(
+ -DL_ENDIAN
+ -DOPENSSL_PIC
+ -DOPENSSL_IA32_SSE2
+ -DOPENSSL_BN_ASM_MONT5
+ -DOPENSSL_BN_ASM_GF2m
+ -DRC4_ASM
+ -DMD5_ASM
+ -DGHASH_ASM
+ -DECP_NISTZ256_ASM
+ -DX25519_ASM
+ -D_REENTRANT
+ )
+ SRCS(
+ ../asm/ios/x86_64/crypto/md5/md5-x86_64.s
+ ../asm/ios/x86_64/crypto/rc4/rc4-md5-x86_64.s
+ ../asm/ios/x86_64/crypto/rc4/rc4-x86_64.s
+ ../asm/ios/x86_64/crypto/modes/ghash-x86_64.s
+ ../asm/ios/x86_64/crypto/modes/aesni-gcm-x86_64.s
+ ../asm/ios/x86_64/crypto/chacha/chacha-x86_64.s
+ ../asm/ios/x86_64/crypto/ec/ecp_nistz256-x86_64.s
+ ../asm/ios/x86_64/crypto/ec/x25519-x86_64.s
+ ../asm/ios/x86_64/crypto/x86_64cpuid.s
+ ../asm/ios/x86_64/crypto/poly1305/poly1305-x86_64.s
+ ../asm/ios/x86_64/crypto/bn/rsaz-x86_64.s
+ ../asm/ios/x86_64/crypto/bn/x86_64-mont.s
+ ../asm/ios/x86_64/crypto/bn/x86_64-gf2m.s
+ ../asm/ios/x86_64/crypto/bn/x86_64-mont5.s
+ ../asm/ios/x86_64/crypto/bn/rsaz-avx2.s
+ ../asm/ios/x86_64/crypto/sha/sha512-x86_64.s
+ ../asm/ios/x86_64/crypto/sha/sha256-x86_64.s
+ ../asm/ios/x86_64/crypto/sha/keccak1600-x86_64.s
+ ../asm/ios/x86_64/crypto/sha/sha1-x86_64.s
+ ../asm/ios/x86_64/crypto/sha/sha1-mb-x86_64.s
+ ../asm/ios/x86_64/crypto/sha/sha256-mb-x86_64.s
+ ../asm/ios/x86_64/crypto/camellia/cmll-x86_64.s
+ ../asm/ios/x86_64/crypto/whrlpool/wp-x86_64.s
+ ../asm/ios/x86_64/crypto/aes/vpaes-x86_64.s
+ ../asm/ios/x86_64/crypto/aes/aesni-sha1-x86_64.s
+ ../asm/ios/x86_64/crypto/aes/aesni-sha256-x86_64.s
+ ../asm/ios/x86_64/crypto/aes/aesni-x86_64.s
+ ../asm/ios/x86_64/crypto/aes/aesni-mb-x86_64.s
+ bn/asm/x86_64-gcc.c
+ bn/rsaz_exp.c
+ dso/dso_dlfcn.c
+ rand/rand_vms.c
+ )
+ENDIF()
+
+IF (OS_IOS AND ARCH_I386)
+ CFLAGS(
+ -DL_ENDIAN
+ -DOPENSSL_PIC
+ -DOPENSSL_BN_ASM_PART_WORDS
+ -DOPENSSL_IA32_SSE2
+ -DOPENSSL_BN_ASM_GF2m
+ -DRC4_ASM
+ -DMD5_ASM
+ -DRMD160_ASM
+ -DWHIRLPOOL_ASM
+ -DGHASH_ASM
+ -D_REENTRANT
+ )
+ SRCS(
+ ../asm/ios/i386/crypto/md5/md5-586.s
+ ../asm/ios/i386/crypto/rc4/rc4-586.s
+ ../asm/ios/i386/crypto/des/des-586.s
+ ../asm/ios/i386/crypto/des/crypt586.s
+ ../asm/ios/i386/crypto/modes/ghash-x86.s
+ ../asm/ios/i386/crypto/x86cpuid.s
+ ../asm/ios/i386/crypto/chacha/chacha-x86.s
+ ../asm/ios/i386/crypto/ec/ecp_nistz256-x86.s
+ ../asm/ios/i386/crypto/poly1305/poly1305-x86.s
+ ../asm/ios/i386/crypto/bf/bf-586.s
+ ../asm/ios/i386/crypto/bn/co-586.s
+ ../asm/ios/i386/crypto/bn/x86-mont.s
+ ../asm/ios/i386/crypto/bn/x86-gf2m.s
+ ../asm/ios/i386/crypto/bn/bn-586.s
+ ../asm/ios/i386/crypto/sha/sha512-586.s
+ ../asm/ios/i386/crypto/sha/sha1-586.s
+ ../asm/ios/i386/crypto/sha/sha256-586.s
+ ../asm/ios/i386/crypto/camellia/cmll-x86.s
+ ../asm/ios/i386/crypto/whrlpool/wp-mmx.s
+ ../asm/ios/i386/crypto/ripemd/rmd-586.s
+ ../asm/ios/i386/crypto/aes/vpaes-x86.s
+ ../asm/ios/i386/crypto/aes/aesni-x86.s
+ ../asm/ios/i386/engines/e_padlock-x86.s
+ dso/dso_dlfcn.c
+ rand/rand_vms.c
+ sha/keccak1600.c
+ whrlpool/wp_block.c
+ )
+ENDIF()
+
+IF (OS_ANDROID AND ARCH_X86_64)
+ CFLAGS(
+ -DOPENSSL_USE_NODELETE
+ -DOPENSSL_PIC
+ -DOPENSSL_IA32_SSE2
+ -DOPENSSL_BN_ASM_MONT5
+ -DOPENSSL_BN_ASM_GF2m
+ -DRC4_ASM
+ -DMD5_ASM
+ -DGHASH_ASM
+ -DX25519_ASM
+ )
+ SRCS(
+ ../asm/android/x86_64/crypto/ec/x25519-x86_64.s
+ ../asm/android/x86_64/crypto/ec/ecp_nistz256-x86_64.s
+ ../asm/android/x86_64/crypto/md5/md5-x86_64.s
+ ../asm/android/x86_64/crypto/rc4/rc4-x86_64.s
+ ../asm/android/x86_64/crypto/rc4/rc4-md5-x86_64.s
+ ../asm/android/x86_64/crypto/whrlpool/wp-x86_64.s
+ ../asm/android/x86_64/crypto/poly1305/poly1305-x86_64.s
+ ../asm/android/x86_64/crypto/x86_64cpuid.s
+ ../asm/android/x86_64/crypto/camellia/cmll-x86_64.s
+ ../asm/android/x86_64/crypto/bn/x86_64-mont5.s
+ ../asm/android/x86_64/crypto/bn/rsaz-avx2.s
+ ../asm/android/x86_64/crypto/bn/rsaz-x86_64.s
+ ../asm/android/x86_64/crypto/bn/x86_64-mont.s
+ ../asm/android/x86_64/crypto/bn/x86_64-gf2m.s
+ ../asm/android/x86_64/crypto/aes/aesni-sha256-x86_64.s
+ ../asm/android/x86_64/crypto/aes/aesni-mb-x86_64.s
+ ../asm/android/x86_64/crypto/aes/aesni-x86_64.s
+ ../asm/android/x86_64/crypto/aes/vpaes-x86_64.s
+ ../asm/android/x86_64/crypto/aes/aesni-sha1-x86_64.s
+ ../asm/android/x86_64/crypto/sha/sha256-x86_64.s
+ ../asm/android/x86_64/crypto/sha/sha1-mb-x86_64.s
+ ../asm/android/x86_64/crypto/sha/sha1-x86_64.s
+ ../asm/android/x86_64/crypto/sha/sha256-mb-x86_64.s
+ ../asm/android/x86_64/crypto/sha/sha512-x86_64.s
+ ../asm/android/x86_64/crypto/sha/keccak1600-x86_64.s
+ ../asm/android/x86_64/crypto/chacha/chacha-x86_64.s
+ ../asm/android/x86_64/crypto/modes/ghash-x86_64.s
+ ../asm/android/x86_64/crypto/modes/aesni-gcm-x86_64.s
+ bn/asm/x86_64-gcc.c
+ bn/rsaz_exp.c
+ dso/dso_dlfcn.c
+ rand/rand_vms.c
+ )
+ENDIF()
+
+IF (OS_ANDROID AND ARCH_I686)
+ CFLAGS(
+ -DOPENSSL_PIC
+ -DOPENSSL_BN_ASM_PART_WORDS
+ -DOPENSSL_IA32_SSE2
+ -DOPENSSL_BN_ASM_GF2m
+ -DRC4_ASM
+ -DMD5_ASM
+ -DRMD160_ASM
+ -DWHIRLPOOL_ASM
+ -DGHASH_ASM
+ )
+ SRCS(
+ ../asm/android/i686/crypto/ec/ecp_nistz256-x86.s
+ ../asm/android/i686/crypto/bf/bf-586.s
+ ../asm/android/i686/crypto/md5/md5-586.s
+ ../asm/android/i686/crypto/rc4/rc4-586.s
+ ../asm/android/i686/crypto/whrlpool/wp-mmx.s
+ ../asm/android/i686/crypto/x86cpuid.s
+ ../asm/android/i686/crypto/des/crypt586.s
+ ../asm/android/i686/crypto/des/des-586.s
+ ../asm/android/i686/crypto/poly1305/poly1305-x86.s
+ ../asm/android/i686/crypto/ripemd/rmd-586.s
+ ../asm/android/i686/crypto/camellia/cmll-x86.s
+ ../asm/android/i686/crypto/bn/bn-586.s
+ ../asm/android/i686/crypto/bn/co-586.s
+ ../asm/android/i686/crypto/bn/x86-gf2m.s
+ ../asm/android/i686/crypto/bn/x86-mont.s
+ ../asm/android/i686/crypto/aes/aesni-x86.s
+ ../asm/android/i686/crypto/aes/vpaes-x86.s
+ ../asm/android/i686/crypto/sha/sha512-586.s
+ ../asm/android/i686/crypto/sha/sha256-586.s
+ ../asm/android/i686/crypto/sha/sha1-586.s
+ ../asm/android/i686/crypto/chacha/chacha-x86.s
+ ../asm/android/i686/crypto/modes/ghash-x86.s
+ dso/dso_dlfcn.c
+ rand/rand_vms.c
+ sha/keccak1600.c
+ whrlpool/wp_block.c
+ )
+ENDIF()
+
+IF (OS_ANDROID AND ARCH_ARM7)
IF (CLANG)
# XXX: This is a workarond for 'out of range immediate fixup value'
# error with clang integrated assembler:
# https://github.com/openssl/openssl/issues/7878
- CFLAGS(
- -mno-thumb
- )
+ CFLAGS(
+ -mno-thumb
+ )
ENDIF()
- CFLAGS(
- -DOPENSSL_PIC
- -DOPENSSL_BN_ASM_GF2m
- -DAES_ASM
- -DBSAES_ASM
- -DGHASH_ASM
- )
- SRCS(
- ../asm/android/arm/crypto/ec/ecp_nistz256-armv4.S
- ../asm/android/arm/crypto/poly1305/poly1305-armv4.S
- ../asm/android/arm/crypto/armv4cpuid.S
- ../asm/android/arm/crypto/bn/armv4-mont.S
- ../asm/android/arm/crypto/bn/armv4-gf2m.S
- ../asm/android/arm/crypto/aes/aes-armv4.S
- ../asm/android/arm/crypto/aes/bsaes-armv7.S
- ../asm/android/arm/crypto/aes/aesv8-armx.S
- ../asm/android/arm/crypto/sha/keccak1600-armv4.S
- ../asm/android/arm/crypto/sha/sha256-armv4.S
- ../asm/android/arm/crypto/sha/sha512-armv4.S
- ../asm/android/arm/crypto/sha/sha1-armv4-large.S
- ../asm/android/arm/crypto/chacha/chacha-armv4.S
- ../asm/android/arm/crypto/modes/ghashv8-armx.S
- ../asm/android/arm/crypto/modes/ghash-armv4.S
- armcap.c
- bn/bn_asm.c
- camellia/camellia.c
- camellia/cmll_cbc.c
- dso/dso_dlfcn.c
- rand/rand_vms.c
- rc4/rc4_enc.c
- rc4/rc4_skey.c
- whrlpool/wp_block.c
- )
-ENDIF()
-
-IF (OS_ANDROID AND ARCH_ARM64)
- CFLAGS(
- -DOPENSSL_PIC
- )
- SRCS(
- ../asm/android/arm64/crypto/ec/ecp_nistz256-armv8.S
- ../asm/android/arm64/crypto/poly1305/poly1305-armv8.S
- ../asm/android/arm64/crypto/bn/armv8-mont.S
- ../asm/android/arm64/crypto/aes/vpaes-armv8.S
- ../asm/android/arm64/crypto/aes/aesv8-armx.S
- ../asm/android/arm64/crypto/sha/sha512-armv8.S
- ../asm/android/arm64/crypto/sha/keccak1600-armv8.S
- ../asm/android/arm64/crypto/sha/sha1-armv8.S
- ../asm/android/arm64/crypto/sha/sha256-armv8.S
- ../asm/android/arm64/crypto/arm64cpuid.S
- ../asm/android/arm64/crypto/chacha/chacha-armv8.S
- ../asm/android/arm64/crypto/modes/ghashv8-armx.S
- armcap.c
- bn/bn_asm.c
- camellia/camellia.c
+ CFLAGS(
+ -DOPENSSL_PIC
+ -DOPENSSL_BN_ASM_GF2m
+ -DAES_ASM
+ -DBSAES_ASM
+ -DGHASH_ASM
+ )
+ SRCS(
+ ../asm/android/arm/crypto/ec/ecp_nistz256-armv4.S
+ ../asm/android/arm/crypto/poly1305/poly1305-armv4.S
+ ../asm/android/arm/crypto/armv4cpuid.S
+ ../asm/android/arm/crypto/bn/armv4-mont.S
+ ../asm/android/arm/crypto/bn/armv4-gf2m.S
+ ../asm/android/arm/crypto/aes/aes-armv4.S
+ ../asm/android/arm/crypto/aes/bsaes-armv7.S
+ ../asm/android/arm/crypto/aes/aesv8-armx.S
+ ../asm/android/arm/crypto/sha/keccak1600-armv4.S
+ ../asm/android/arm/crypto/sha/sha256-armv4.S
+ ../asm/android/arm/crypto/sha/sha512-armv4.S
+ ../asm/android/arm/crypto/sha/sha1-armv4-large.S
+ ../asm/android/arm/crypto/chacha/chacha-armv4.S
+ ../asm/android/arm/crypto/modes/ghashv8-armx.S
+ ../asm/android/arm/crypto/modes/ghash-armv4.S
+ armcap.c
+ bn/bn_asm.c
+ camellia/camellia.c
+ camellia/cmll_cbc.c
+ dso/dso_dlfcn.c
+ rand/rand_vms.c
+ rc4/rc4_enc.c
+ rc4/rc4_skey.c
+ whrlpool/wp_block.c
+ )
+ENDIF()
+
+IF (OS_ANDROID AND ARCH_ARM64)
+ CFLAGS(
+ -DOPENSSL_PIC
+ )
+ SRCS(
+ ../asm/android/arm64/crypto/ec/ecp_nistz256-armv8.S
+ ../asm/android/arm64/crypto/poly1305/poly1305-armv8.S
+ ../asm/android/arm64/crypto/bn/armv8-mont.S
+ ../asm/android/arm64/crypto/aes/vpaes-armv8.S
+ ../asm/android/arm64/crypto/aes/aesv8-armx.S
+ ../asm/android/arm64/crypto/sha/sha512-armv8.S
+ ../asm/android/arm64/crypto/sha/keccak1600-armv8.S
+ ../asm/android/arm64/crypto/sha/sha1-armv8.S
+ ../asm/android/arm64/crypto/sha/sha256-armv8.S
+ ../asm/android/arm64/crypto/arm64cpuid.S
+ ../asm/android/arm64/crypto/chacha/chacha-armv8.S
+ ../asm/android/arm64/crypto/modes/ghashv8-armx.S
+ armcap.c
+ bn/bn_asm.c
+ camellia/camellia.c
camellia/cmll_cbc.c
- dso/dso_dlfcn.c
- rand/rand_vms.c
- rc4/rc4_enc.c
- rc4/rc4_skey.c
- whrlpool/wp_block.c
- )
-ENDIF()
-
+ dso/dso_dlfcn.c
+ rand/rand_vms.c
+ rc4/rc4_enc.c
+ rc4/rc4_skey.c
+ whrlpool/wp_block.c
+ )
+ENDIF()
+
END()