Changeset 432 for server


Ignore:
Timestamp:
Sep 26, 2007, 7:58:06 PM (15 years ago)
Author:
andersk
Message:
Backquotes and regular expressions are SHIT.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • server/common/oursrc/accountadm/signup-scripts-backend.in

    r378 r432  
    4040}
    4141
    42 # Tell AFS that we don't want to trigger fakestat
    43 chdir $homedir;
     42# Tell AFS that we don't want to trigger fakestat, and confirm user's homedir
     43chdir $homedir or complain("athena homedir not found");
    4444
    45 # Run ls to confirm user's homedir and obtain user's homedir uid
    46 my $ls_regexp = '^\S*\s+\S*\s+(\S*)\s+(\S*)\s+\S*\s+\S*\s+\S*\s+\S*\s+(\S*).*$';
    47 my ($uid1, $gid1, $name1) = (`@ls_path@ -dln '$homedir'` =~ $ls_regexp);
    48 
    49 # Complain if user's homedir does not exist
    50 complain("athena homedir not found") unless($name1 eq $homedir);
     45# Obtain user's homedir uid
     46my ($spam, $spam, $spam, $spam, $uid1, $gid1, $spam, $spam, $spam, $spam, $spam, $egg, $spam) = stat '.' or complain("athena homedir not found");
    5147
    5248# Complain if user's uid is too low or too high
    5349complain("bad uid") unless($uid1 > 110 and $uid1 < (1 << 31));
    5450
    55 # Run ls to confirm user's .scripts-signup file
    56 my ($uid2, $gid2, $name2) = (`@ls_path@ -dln '$homedir/.scripts-signup'` =~ $ls_regexp);
    57 
    5851# Complain if user's .scripts-signup file does not exist
    59 #complain("scripts-signup file not found") unless($name2 eq "$homedir/.scripts-signup");
     52#complain("scripts-signup file not found") unless(-e '.scripts-signup');
    6053
    6154# Complain if the user's username is already taken
Note: See TracChangeset for help on using the changeset viewer.