Commit 03aad12c authored by Srikanth's avatar Srikanth

fixed soem bugs

parent 658b0ccb
...@@ -16,7 +16,7 @@ PSBIN_STUFF = register_resources expire_daemon gencrl postcrl \ ...@@ -16,7 +16,7 @@ PSBIN_STUFF = register_resources expire_daemon gencrl postcrl \
createcerts initsite addauthority getcacerts \ createcerts initsite addauthority getcacerts \
gencrlbundle shutdownslice remauthority listusage \ gencrlbundle shutdownslice remauthority listusage \
update reregister cleanupticket listhistory \ update reregister cleanupticket listhistory \
register_sliver sa_daemon register_sliver sa_daemon genadmincredential
# These scripts installed setuid, with sudo. # These scripts installed setuid, with sudo.
SETUID_BIN_SCRIPTS = SETUID_BIN_SCRIPTS =
......
#!/usr/bin/perl -wT #!/usr/bin/perl -w
# #
# GENIPUBLIC-COPYRIGHT # GENIPUBLIC-COPYRIGHT
# Copyright (c) 2008-2009 University of Utah and the Flux Group. # Copyright (c) 2008-2009 University of Utah and the Flux Group.
# All rights reserved. # All rights reserved.
# #
use strict; use strict;
use lib '@prefix@/lib';
use Exporter;
use vars qw(@ISA @EXPORT);
@ISA = "Exporter";
@EXPORT = qw ( );
use GeniCredential; use GeniCredential;
use GeniCertificate; use GeniCertificate;
...@@ -19,7 +14,7 @@ use GeniHRN; ...@@ -19,7 +14,7 @@ use GeniHRN;
use GeniResponse; use GeniResponse;
use GeniUser; use GeniUser;
sub CreateAdminCredential() sub CreateAdminCredential
{ {
my $owner_urn = shift; my $owner_urn = shift;
my $target_cm_urn = shift; my $target_cm_urn = shift;
...@@ -44,7 +39,7 @@ sub CreateAdminCredential() ...@@ -44,7 +39,7 @@ sub CreateAdminCredential()
my $credential = my $credential =
GeniCredential->CreateSigned($authority, GeniCredential->CreateSigned($authority,
$geniuser, $geniuser,
$GeniCredential::LOCALSA_FLAG); $GeniCredential::LOCALCM_FLAG);
return GeniResponse->Create(GENIRESPONSE_ERROR) return GeniResponse->Create(GENIRESPONSE_ERROR)
if (!defined($credential)); if (!defined($credential));
...@@ -53,6 +48,8 @@ sub CreateAdminCredential() ...@@ -53,6 +48,8 @@ sub CreateAdminCredential()
} }
print CreateAdminCredential @ARGV my $val = CreateAdminCredential @ARGV;
print $val->{"code"};
print $val->{"value"};
print $val->{"output"};
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment