Dolda2000 GitWeb
/
utils.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
f2571f8
)
Slightly dubious certreq adjustments.
author
Fredrik Tolf
<fredrik@dolda2000.com>
Sat, 24 Mar 2018 00:23:21 +0000
(
01:23
+0100)
committer
Fredrik Tolf
<fredrik@dolda2000.com>
Sat, 24 Mar 2018 00:23:21 +0000
(
01:23
+0100)
certreq
patch
|
blob
|
blame
|
history
diff --git
a/certreq
b/certreq
index
fb7e26c
..
142644e
100755
(executable)
--- a/
certreq
+++ b/
certreq
@@
-1,5
+1,14
@@
#!/bin/bash
#!/bin/bash
+commajoin() {
+ f=y
+ for arg in "$@"; do
+ if [ -z "$f" ]; then echo -n ,; fi
+ echo -n "$arg"
+ f=
+ done
+}
+
usage() {
echo "usage: certreq [-h] [-a ALTNAMES] SUBJECT KEYFILE"
echo ' SUBJECT is of the form `/PART1=VALUE1/PART2=VALUE2/...'\'
usage() {
echo "usage: certreq [-h] [-a ALTNAMES] SUBJECT KEYFILE"
echo ' SUBJECT is of the form `/PART1=VALUE1/PART2=VALUE2/...'\'
@@
-28,7
+37,9
@@
fi
args=(openssl req -new)
if [ -n "${!reqexts[*]}" ]; then
args=(openssl req -new)
if [ -n "${!reqexts[*]}" ]; then
- args=("${args[@]}" -reqexts "${!reqexts[@]}")
+ for reqext in "${!reqexts[@]}"; do
+ args=("${args[@]}" -reqexts "$reqext")
+ done
fi
if [ -n "${!config[*]}" ]; then
confpath="$(mktemp /tmp/certreq-XXXXXX)"
fi
if [ -n "${!config[*]}" ]; then
confpath="$(mktemp /tmp/certreq-XXXXXX)"