Skip to content

Commit 7c3c798

Browse files
committedNov 2, 2024·
regex
1 parent c9fd7da commit 7c3c798

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed
 

‎src/test_certs_r4_with_bc.sh

+3
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@ test_ta () {
2323

2424
tafileBasename=$(basename $tafile)
2525

26+
# strip off the friendly name
27+
tafileBasename=$(echo $tafileBasename | egrep -o '[^-]+_ta.der$')
28+
2629
# strip off the file suffix to get the OID name
2730
if [[ $(expr match "$tafileBasename" ".*_ta\.pem$") != 0 ]]; then
2831
oid=${tafileBasename%_ta.pem}

‎src/test_certs_r4_with_oqs.sh

+1-4
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,7 @@ test_ta () {
2626

2727
# strip off the file suffix to get the OID name
2828
if [[ $(expr match "$tafileBasename" ".*_ta\.der$") != 0 ]]; then
29-
oid=${tafileBasename%_ta.der}
30-
31-
printf "DEBUG: filename: $tafileBasename, OID: $oid\n"
32-
29+
oid=${tafileBasename%_ta.der}
3330
else # It's some other filename
3431
printf "ERROR: file name is not in the expected format: %s\n" $tafileBasename
3532
printf "ERROR: file name is not in the expected format: %s\n" $tafileBasename >> $logfile

0 commit comments

Comments
 (0)
Please sign in to comment.