cid#1636693 COPY_INSTEAD_OF_MOVE
[LibreOffice.git] / xmlsecurity / qa / create-certs / create-dump-certs.sh
blob95e8de9c6f5a13cf7336613fc05db6a48d919bd1
1 #!/usr/bin/env bash
3 # This file is part of the LibreOffice project.
5 # This Source Code Form is subject to the terms of the Mozilla Public
6 # License, v. 2.0. If a copy of the MPL was not distributed with this
7 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 # This script generates 100 certificates (modifiable) for cases of testing UI latency for instance.
11 # Basically, it creates certificates with sender same as receiver following User [number] pattern.
14 for ((i=1; i<=100; i++))
16 gpg --batch --gen-key <<EOF
17 %no-protection
18 Key-Type: RSA
19 Key-Length: 2048
20 Subkey-Type: RSA
21 Subkey-Length: 2048
22 Name-Real: User $i
23 Name-Email: user$i@example.com
24 Expire-Date: 1y
25 %commit
26 EOF
28 gpg --armor --export user$i@example.com > user$i.asc
30 echo "Generated certificate for User $i"
31 done