Fix copyright year issues
authorBernd Edlinger <bernd.edlinger@hotmail.de>
Wed, 5 Jan 2022 16:25:02 +0000 (17:25 +0100)
committerBernd Edlinger <bernd.edlinger@hotmail.de>
Thu, 6 Jan 2022 08:27:02 +0000 (09:27 +0100)
Fixes: #13765
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/17427)

.github/workflows/ci.yml
crypto/asn1/charmap.h
crypto/bn/bn_prime.h
crypto/conf/conf_def.h
crypto/objects/obj_xref.h
include/openssl/obj_mac.h
util/perl/OpenSSL/copyright.pm

index 103f4c774f8543f7ce9f2d74132503a018f58122..1f0ad4bc173ee4b9b9b7572aac983eb23c718d6e 100644 (file)
@@ -27,6 +27,8 @@ jobs:
         sudo apt-get update
         sudo apt-get -yq --no-install-suggests --no-install-recommends --force-yes install unifdef
     - uses: actions/checkout@v2
+      with:
+        fetch-depth: 0
     - name: config
       run: ./config --banner=Configured --strict-warnings enable-fips && perl configdata.pm --dump
     - name: make build_generated
index 95928ca6633a1e0d6299b06e2ec5d7136e09cde2..ac1eb076cc2603c490cff9c90a3460e0f091d71b 100644 (file)
@@ -2,7 +2,7 @@
  * WARNING: do not edit!
  * Generated by crypto/asn1/charmap.pl
  *
- * Copyright 2000-2022 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2000-2021 The OpenSSL Project Authors. All Rights Reserved.
  *
  * Licensed under the Apache License 2.0 (the "License").  You may not use
  * this file except in compliance with the License.  You can obtain a copy
index d92f6dfa69a727493a4a59b807ba5a91b6c6f12d..8a859ac02e266b03de98a24695fd762c332d4bcc 100644 (file)
@@ -2,7 +2,7 @@
  * WARNING: do not edit!
  * Generated by crypto/bn/bn_prime.pl
  *
- * Copyright 1998-2022 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1998-2021 The OpenSSL Project Authors. All Rights Reserved.
  *
  * Licensed under the Apache License 2.0 (the "License").  You may not use
  * this file except in compliance with the License.  You can obtain a copy
index e5321bd30d9ca9b13a645bc3db983b1f80fabc65..1f66a58e092318a6fe5f061a0b3c450650a5b5a1 100644 (file)
@@ -2,7 +2,7 @@
  * WARNING: do not edit!
  * Generated by crypto/conf/keysets.pl
  *
- * Copyright 1995-2022 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
  * Licensed under the Apache License 2.0 (the "License").  You may not use
  * this file except in compliance with the License.  You can obtain a copy
  * in the file LICENSE in the source distribution or at
index c08b5fc2aba07b8a29b6c1ff1a8999d0a77ca07e..21a193ee98bc22dd10bc6bcf7261774f1fc49f13 100644 (file)
@@ -2,7 +2,7 @@
  * WARNING: do not edit!
  * Generated by objxref.pl
  *
- * Copyright 1998-2022 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 1998-2021 The OpenSSL Project Authors. All Rights Reserved.
  *
  * Licensed under the Apache License 2.0 (the "License").  You may not use
  * this file except in compliance with the License.  You can obtain a copy
index fb788d43d5f1078b52c605f0ecb29a634e2446a1..a9e51d7b38106978debb520b1c646359063a305e 100644 (file)
@@ -2,7 +2,7 @@
  * WARNING: do not edit!
  * Generated by crypto/objects/objects.pl
  *
- * Copyright 2000-2022 The OpenSSL Project Authors. All Rights Reserved.
+ * Copyright 2000-2021 The OpenSSL Project Authors. All Rights Reserved.
  * Licensed under the Apache License 2.0 (the "License").  You may not use
  * this file except in compliance with the License.  You can obtain a copy
  * in the file LICENSE in the source distribution or at
index 1fd9f353f7fc80ad6339a26f813efeecab78eab2..b82b67a0e6ff8d4bdaf4b03d83ebee7043bc7d82 100644 (file)
@@ -23,11 +23,11 @@ sub year_of {
 
     # See if git's available
     open my $FH,
-       "git log -1 --date=format:%Y --format=format:%ad $file 2>/dev/null|"
+       "git log -1 --date=short --format=format:%cd $file 2>/dev/null|"
            or return $YEAR;
     my $LINE = <$FH>;
     close $FH;
-    chomp($LINE);
+    $LINE =~ s/^([0-9]*)-.*/$1/;
     $YEAR = $LINE if $LINE;
     return $YEAR;
 }