Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emulab
emulab-devel
Commits
8c624fed
Commit
8c624fed
authored
Sep 01, 2011
by
Leigh B Stoller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Minor fix.
parent
83a9f7a1
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
4 deletions
+8
-4
protogeni/scripts/addauthority.in
protogeni/scripts/addauthority.in
+7
-3
protogeni/scripts/fixcerts.in
protogeni/scripts/fixcerts.in
+1
-1
No files found.
protogeni/scripts/addauthority.in
View file @
8c624fed
#!/usr/bin/perl -w
#!/usr/bin/perl -w
#
#
# GENIPUBLIC-COPYRIGHT
# GENIPUBLIC-COPYRIGHT
# Copyright (c) 2008-201
0
University of Utah and the Flux Group.
# Copyright (c) 2008-201
1
University of Utah and the Flux Group.
# All rights reserved.
# All rights reserved.
#
#
use
strict
;
use
strict
;
...
@@ -18,10 +18,11 @@ sub usage()
...
@@ -18,10 +18,11 @@ sub usage()
print
"
Usage: addauthority [-c] [-a] [-n] <certfile> <type> [url]
\n
";
print
"
Usage: addauthority [-c] [-a] [-n] <certfile> <type> [url]
\n
";
exit
(
1
);
exit
(
1
);
}
}
my
$optlist
=
"
acn
";
my
$optlist
=
"
acn
f
";
my
$asch
=
0
;
my
$asch
=
0
;
my
$asam
=
0
;
my
$asam
=
0
;
my
$disable
=
0
;
my
$disable
=
0
;
my
$force
=
0
;
#
#
# Check args.
# Check args.
...
@@ -39,6 +40,9 @@ if (defined($options{"c"})) {
...
@@ -39,6 +40,9 @@ if (defined($options{"c"})) {
if
(
defined
(
$options
{"
a
"}))
{
if
(
defined
(
$options
{"
a
"}))
{
$asam
=
1
;
$asam
=
1
;
}
}
if
(
defined
(
$options
{"
f
"}))
{
$force
=
1
;
}
usage
()
usage
()
if
(
@ARGV
<
2
||
@ARGV
>
3
);
if
(
@ARGV
<
2
||
@ARGV
>
3
);
...
@@ -73,7 +77,7 @@ if (!defined($url)) {
...
@@ -73,7 +77,7 @@ if (!defined($url)) {
die
("
Certificate does not have a URI extension
");
die
("
Certificate does not have a URI extension
");
}
}
}
}
if
(
GeniAuthority
->
CheckExisting
(
$certificate
))
{
if
(
!
$force
&&
GeniAuthority
->
CheckExisting
(
$certificate
))
{
die
("
$certfile
is already registered in the DB
\n
");
die
("
$certfile
is already registered in the DB
\n
");
}
}
my
$authority
=
GeniAuthority
->
Create
(
$certificate
,
$url
,
lc
(
$type
));
my
$authority
=
GeniAuthority
->
Create
(
$certificate
,
$url
,
lc
(
$type
));
...
...
protogeni/scripts/fixcerts.in
View file @
8c624fed
...
@@ -97,7 +97,7 @@ if ($asch) {
...
@@ -97,7 +97,7 @@ if ($asch) {
system
("
$UPDATECERT
$CHCERT
")
==
0
or
system
("
$UPDATECERT
$CHCERT
")
==
0
or
fatal
("
Could not update
$CHCERT
");
fatal
("
Could not update
$CHCERT
");
system
("
$ADDAUTHORITY
-c
$CHCERT
ma
")
==
0
system
("
$ADDAUTHORITY
-f
-c
$CHCERT
ma
")
==
0
or
fatal
("
Could not add CH certificate to CH DB
");
or
fatal
("
Could not add CH certificate to CH DB
");
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment