Changeset 2576 for branches/fc20-dev


Ignore:
Timestamp:
Aug 24, 2014, 11:45:46 PM (8 years ago)
Author:
achernya
Message:
Merge r2553:2575 from trunk into branches/fc20-dev
Location:
branches/fc20-dev
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/fc20-dev

    • Property svn:mergeinfo changed
      /trunkmerged: 2575
  • branches/fc20-dev/locker

    • Property svn:mergeinfo changed (with no actual effect on merging)
  • branches/fc20-dev/server/common/oursrc/accountadm/signup-scripts-backend.in

    r2101 r2576  
    11#!/usr/bin/perl
    22use strict;
     3use File::Temp qw/ :POSIX /;
    34
    45# signup-scripts-backend
     
    102103}
    103104
     105# Get credentials
     106my $ccache = tmpnam();
     107$ENV{'KRB5CCNAME'} = $ccache;
     108my $exit_status = system("/usr/bin/kinit", "-k", "-t", "/etc/signup.keytab", "daemon/scripts-signup.mit.edu");
     109if (($exit_status >> 8) != 0) {
     110    die "Couldn't get Kerberos credentials for account creation!";
     111}
    104112my $pid;
     113my @ldap_servers = ('doppelganger', 'alter-ego', 'body-double');
     114my $selected_server = $ldap_servers[int(rand(3))];
    105115defined ($pid = open LDAP, '|-') or complain("internal error");
    106116if (!$pid) {
    107117        close STDOUT;
    108118        open STDOUT, '>/dev/null';
    109         exec '@ldapadd_path@', '-c', '-x', '-D', 'cn=Directory Manager', '-y', '/etc/signup-ldap-pw';
     119        exec '@ldapadd_path@', '-c', '-Y', 'gssapi', '-H', "ldap://$selected_server.mit.edu";
    110120        exit 1;
    111121}
     
    145155#system('@sudo_path@', '-u', 'root', '/usr/sbin/setquota', $username, '0', '25000', '0', '10000', '-a');
    146156
     157system("kdestroy");
     158
    147159printexit("done", 0);
    148160
Note: See TracChangeset for help on using the changeset viewer.