From 9474e5f45e94937d1292454d07b4e161b3e56d49 Mon Sep 17 00:00:00 2001 From: Kiko Fernandez-Reyes Date: Wed, 20 Nov 2024 12:47:17 +0100 Subject: [PATCH] otp: add missing licenses to files added in OTP-27 --- SECURITY.md | 24 +++++++++++++++++-- .../empty_group_SUITE.erl | 20 ++++++++++++++++ .../ss_depth_limit.erl | 20 ++++++++++++++++ .../test/compile_SUITE_data/exceptions.erl | 21 +++++++++++++++- .../results/logical_processors | 8 +++---- .../src/logical_processors.erl | 20 ++++++++++++++++ lib/kernel/test/os_SUITE_data/sys_shell.c | 20 ++++++++++++++++ .../test/mnesia_external_backend_test.erl | 20 ++++++++++++++++ lib/public_key/test/public_key_SUITE.erl | 13 +++++++++- .../public_key_SUITE_data/pss_default.pem | 19 +++++++++++++++ .../public_key_SUITE_data/public_eddsa.pem | 19 +++++++++++++++ .../test/ssh_dbg_SUITE_data/ssh_host_rsa_key | 20 ++++++++++++++++ make/ex_doc_wrapper.in | 21 ++++++++++++++++ 13 files changed, 237 insertions(+), 8 deletions(-) diff --git a/SECURITY.md b/SECURITY.md index ffb1d6ec216d..95ba4cb787e1 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -1,3 +1,25 @@ + + # Security Policy ## Reporting a Vulnerability and/or Security Issues @@ -21,5 +43,3 @@ For example, if the latest release is OTP-27, we will support with maintainance | =< 24 | :x: | - - diff --git a/lib/common_test/test/ct_misc_1_SUITE_data/empty_group_SUITE.erl b/lib/common_test/test/ct_misc_1_SUITE_data/empty_group_SUITE.erl index 66cc587f2b19..34593c2d502f 100644 --- a/lib/common_test/test/ct_misc_1_SUITE_data/empty_group_SUITE.erl +++ b/lib/common_test/test/ct_misc_1_SUITE_data/empty_group_SUITE.erl @@ -1,3 +1,23 @@ +%% +%% %CopyrightBegin% +%% +%% Copyright 2024 Johannes Christ +%% +%% 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. +%% +%% %CopyrightEnd% +%% + -module(empty_group_SUITE). -compile(export_all). -compile(nowarn_export_all). diff --git a/lib/compiler/test/beam_ssa_check_SUITE_data/ss_depth_limit.erl b/lib/compiler/test/beam_ssa_check_SUITE_data/ss_depth_limit.erl index ec91b57f26fa..61cbb7f913aa 100644 --- a/lib/compiler/test/beam_ssa_check_SUITE_data/ss_depth_limit.erl +++ b/lib/compiler/test/beam_ssa_check_SUITE_data/ss_depth_limit.erl @@ -1,3 +1,23 @@ +%% +%% %CopyrightBegin% +%% +%% Copyright Ericsson AB 1996-2024. All Rights Reserved. +%% +%% 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. +%% +%% %CopyrightEnd% +%% + %%% %%% Check that the limit imposed on the depth of sharing state value %%% chains is imposed. diff --git a/lib/compiler/test/compile_SUITE_data/exceptions.erl b/lib/compiler/test/compile_SUITE_data/exceptions.erl index 8cbffdcc5923..98246f3063a4 100644 --- a/lib/compiler/test/compile_SUITE_data/exceptions.erl +++ b/lib/compiler/test/compile_SUITE_data/exceptions.erl @@ -1,3 +1,22 @@ +%% +%% %CopyrightBegin% +%% +%% Copyright Ericsson AB 1996-2024. All Rights Reserved. +%% +%% 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. +%% +%% %CopyrightEnd% +%% -module(exceptions). -export([?MODULE/1]). @@ -10,7 +29,7 @@ wrong_line() -> %Line 4 {'EXIT',{{badmatch,error}, [{?MODULE,wrong_line,0,Loc}|_]}} = catch wrong_line(), - {line,5} = lists:keyfind(line, 1, Loc), + {line,24} = lists:keyfind(line, 1, Loc), ok. diff --git a/lib/dialyzer/test/small_SUITE_data/results/logical_processors b/lib/dialyzer/test/small_SUITE_data/results/logical_processors index d80aa4dac324..695ad37dbf30 100644 --- a/lib/dialyzer/test/small_SUITE_data/results/logical_processors +++ b/lib/dialyzer/test/small_SUITE_data/results/logical_processors @@ -1,5 +1,5 @@ -logical_processors.erl:11:1: Function t1/0 has no local return -logical_processors.erl:12:7: The pattern 'ok' can never match the type 'unknown' | non_neg_integer() -logical_processors.erl:14:1: Function t2/0 has no local return -logical_processors.erl:15:7: The pattern 'ok' can never match the type 'unknown' | non_neg_integer() +logical_processors.erl:31:1: Function t1/0 has no local return +logical_processors.erl:32:7: The pattern 'ok' can never match the type 'unknown' | non_neg_integer() +logical_processors.erl:34:1: Function t2/0 has no local return +logical_processors.erl:35:7: The pattern 'ok' can never match the type 'unknown' | non_neg_integer() diff --git a/lib/dialyzer/test/small_SUITE_data/src/logical_processors.erl b/lib/dialyzer/test/small_SUITE_data/src/logical_processors.erl index 4bdf24432d8a..1b03b698efb7 100644 --- a/lib/dialyzer/test/small_SUITE_data/src/logical_processors.erl +++ b/lib/dialyzer/test/small_SUITE_data/src/logical_processors.erl @@ -1,3 +1,23 @@ +%% +%% %CopyrightBegin% +%% +%% Copyright 2024 Ildar Khizbulin +%% +%% 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. +%% +%% %CopyrightEnd% +%% + -module(logical_processors). -export([t0/0,t1/0,t2/0]). diff --git a/lib/kernel/test/os_SUITE_data/sys_shell.c b/lib/kernel/test/os_SUITE_data/sys_shell.c index 73a8c034501e..341f41d5a86d 100644 --- a/lib/kernel/test/os_SUITE_data/sys_shell.c +++ b/lib/kernel/test/os_SUITE_data/sys_shell.c @@ -1,3 +1,23 @@ +/* + * %CopyrightBegin% + * + * Copyright 2024 Yaroslav Maslennikov + * + * 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. + * + * %CopyrightEnd% + */ + #include int main(void) { diff --git a/lib/mnesia/test/mnesia_external_backend_test.erl b/lib/mnesia/test/mnesia_external_backend_test.erl index 1391be7c8816..b709a9aba2d0 100644 --- a/lib/mnesia/test/mnesia_external_backend_test.erl +++ b/lib/mnesia/test/mnesia_external_backend_test.erl @@ -1,3 +1,23 @@ +%% +%% %CopyrightBegin% +%% +%% Copyright Ericsson AB 1996-2024. All Rights Reserved. +%% +%% 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. +%% +%% %CopyrightEnd% +%% + -module(mnesia_external_backend_test). -export([init_per_testcase/2, end_per_testcase/2, diff --git a/lib/public_key/test/public_key_SUITE.erl b/lib/public_key/test/public_key_SUITE.erl index a85a5d4b017a..5ac238929ec3 100644 --- a/lib/public_key/test/public_key_SUITE.erl +++ b/lib/public_key/test/public_key_SUITE.erl @@ -1876,7 +1876,18 @@ check_encapsulated_header([]) -> strip_superfluous_newlines(Bin) -> Str = string:strip(binary_to_list(Bin), right, 10), - re:replace(Str,"\n\n","\n", [{return,list}, global]). + Str1 = remove_license_header(Str), + re:replace(Str1,"\n\n","\n", [{return,list}, global]). + +remove_license_header("%%" ++ _=String) -> + case string:split(String, "\n") of + [_, Tail] -> + remove_license_header(Tail); + [Other] -> + Other + end; +remove_license_header(Code) -> + Code. do_gen_ec_param(File) -> {ok, KeyPem} = file:read_file(File), diff --git a/lib/public_key/test/public_key_SUITE_data/pss_default.pem b/lib/public_key/test/public_key_SUITE_data/pss_default.pem index 0a9d082fcfe2..1c59da42284a 100644 --- a/lib/public_key/test/public_key_SUITE_data/pss_default.pem +++ b/lib/public_key/test/public_key_SUITE_data/pss_default.pem @@ -1,3 +1,22 @@ +%% +%% %CopyrightBegin% +%% +%% Copyright Ericsson AB 1996-2024. All Rights Reserved. +%% +%% 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. +%% +%% %CopyrightEnd% +%% -----BEGIN PRIVATE KEY----- MIIEuwIBADALBgkqhkiG9w0BAQoEggSnMIIEowIBAAKCAQEAjPwd860nEH6sgfYE RXoAjMY3Rdl3ynuJd5/ZWqTBNGn/Wet8idPQix9nwUvZ6Nw7uGX00HeBITZeIZMo diff --git a/lib/public_key/test/public_key_SUITE_data/public_eddsa.pem b/lib/public_key/test/public_key_SUITE_data/public_eddsa.pem index 43db3af730e8..1336f053d828 100644 --- a/lib/public_key/test/public_key_SUITE_data/public_eddsa.pem +++ b/lib/public_key/test/public_key_SUITE_data/public_eddsa.pem @@ -1,3 +1,22 @@ +%% +%% %CopyrightBegin% +%% +%% Copyright Ericsson AB 1996-2024. All Rights Reserved. +%% +%% 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. +%% +%% %CopyrightEnd% +%% -----BEGIN PUBLIC KEY----- MCowBQYDK2VwAyEAzVMFUvlbihtNisegppBVAct8qRH2Ql3KZ57JAxt8Gms= -----END PUBLIC KEY----- diff --git a/lib/ssh/test/ssh_dbg_SUITE_data/ssh_host_rsa_key b/lib/ssh/test/ssh_dbg_SUITE_data/ssh_host_rsa_key index 79968bdd7d31..3dc6b44bd496 100644 --- a/lib/ssh/test/ssh_dbg_SUITE_data/ssh_host_rsa_key +++ b/lib/ssh/test/ssh_dbg_SUITE_data/ssh_host_rsa_key @@ -1,3 +1,23 @@ +%% +%% %CopyrightBegin% +%% +%% Copyright Ericsson AB 1996-2024. All Rights Reserved. +%% +%% 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. +%% +%% %CopyrightEnd% +%% + -----BEGIN RSA PRIVATE KEY----- MIICXQIBAAKBgQDCZX+4FBDwZIh9y/Uxee1VJnEXlowpz2yDKwj8semM4q843337 zbNfxHmladB1lpz2NqyxI175xMIJuDxogyZdsOxGnFAzAnthR4dqL/RWRWzjaxSB diff --git a/make/ex_doc_wrapper.in b/make/ex_doc_wrapper.in index 8f9b06df31b3..d060f086bffc 100755 --- a/make/ex_doc_wrapper.in +++ b/make/ex_doc_wrapper.in @@ -1,5 +1,26 @@ #!/bin/bash +## +## %CopyrightBegin% +## +## Copyright Ericsson AB 1996-2024. All Rights Reserved. +## +## 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. +## +## %CopyrightEnd% +## + + ARGS=("$@") set -eo pipefail {0}