projects
/
mirror
/
userdir-ldap.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
2fea3b6
)
We don't use the LDAP object in these functions, so I don't see why we're passing...
author
Stephen Gran
<steve@lobefin.net>
Sat, 9 May 2009 13:00:27 +0000
(14:00 +0100)
committer
Stephen Gran
<steve@lobefin.net>
Sat, 9 May 2009 13:00:27 +0000
(14:00 +0100)
ud-generate
patch
|
blob
|
history
diff --git
a/ud-generate
b/ud-generate
index
693e563
..
909cfce
100755
(executable)
--- a/
ud-generate
+++ b/
ud-generate
@@
-157,7
+157,7
@@
def Done(File, F, Fdb):
os.rename(File + ".tdb.tmp", File + ".tdb")
# Generate the password list
os.rename(File + ".tdb.tmp", File + ".tdb")
# Generate the password list
-def GenPasswd(
l,
File, HomePrefix, PwdMarker):
+def GenPasswd(File, HomePrefix, PwdMarker):
F = None
try:
F = open(File + ".tdb.tmp", "w")
F = None
try:
F = open(File + ".tdb.tmp", "w")
@@
-408,7
+408,7
@@
def addGroups(existingGroups, newGroups, uid):
addGroups(existingGroups, SubGroupMap[group], uid)
# Generate the group list
addGroups(existingGroups, SubGroupMap[group], uid)
# Generate the group list
-def GenGroup(
l,
File):
+def GenGroup(File):
grouprevmap = {}
F = None
try:
grouprevmap = {}
F = None
try:
@@
-596,7
+596,7
@@
def GenPrivate(l, File):
Done(File, F, None)
# Generate a list of locked accounts
Done(File, F, None)
# Generate a list of locked accounts
-def GenDisabledAccounts(
l,
File):
+def GenDisabledAccounts(File):
F = None
try:
F = open(File + ".tmp", "w")
F = None
try:
F = open(File + ".tmp", "w")
@@
-1054,7
+1054,7
@@
else:
# Generate global things
GlobalDir = GenerateDir + "/"
# Generate global things
GlobalDir = GenerateDir + "/"
-GenDisabledAccounts(
l,
GlobalDir + "disabled-accounts")
+GenDisabledAccounts(GlobalDir + "disabled-accounts")
for x in PasswdAttrs:
if IsRetired(x):
for x in PasswdAttrs:
if IsRetired(x):
@@
-1124,11
+1124,11
@@
while(1):
sys.stdout.flush()
if ExtraList.has_key("[NOPASSWD]"):
sys.stdout.flush()
if ExtraList.has_key("[NOPASSWD]"):
- userlist = GenPasswd(
l,
OutDir + "passwd", Split[1], "*")
+ userlist = GenPasswd(OutDir + "passwd", Split[1], "*")
else:
else:
- userlist = GenPasswd(
l,
OutDir + "passwd", Split[1], "x")
+ userlist = GenPasswd(OutDir + "passwd", Split[1], "x")
sys.stdout.flush()
sys.stdout.flush()
- grouprevmap = GenGroup(
l,
OutDir + "group")
+ grouprevmap = GenGroup(OutDir + "group")
GenShadowSudo(l, OutDir + "sudo-passwd", ExtraList.has_key("[UNTRUSTED]") or ExtraList.has_key("[NOPASSWD]"))
# Now we know who we're allowing on the machine, export
GenShadowSudo(l, OutDir + "sudo-passwd", ExtraList.has_key("[UNTRUSTED]") or ExtraList.has_key("[NOPASSWD]"))
# Now we know who we're allowing on the machine, export