~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to ivle/makeuser.py

  • Committer: Matt Giuca
  • Date: 2009-04-22 05:14:58 UTC
  • Revision ID: matt.giuca@gmail.com-20090422051458-vh65hoaa3a54knxq
Stopped clobbering conf.py within the jail, using a proper ivle.conf instead.
Now works with Python 2.6 (and can have another version, possible 2.6, inside
the jail).

ivle/config/ivle-spec.conf: Added user_info section with in-jail variables.
ivle/makeuser: Writes a conf file (ivle.conf) instead of conf.py.
ivle/conf/conf.py: Added emulation layer bindings for the in-jail variables.
ivle-buildjail: No longer REMOVES the conf.py file (since it's just a normal
    source file now).

(--author Will)

Show diffs side-by-side

added added

removed removed

Lines of Context:
35
35
# Do not call os.system("chown www-data") - use Python lib
36
36
# and use the web server uid given in conf. (Several places).
37
37
 
38
 
import hashlib
 
38
import md5
39
39
import os
40
40
import stat
41
41
import shutil
124
124
    """Setup svn authentication for the given user.
125
125
       Uses the given DB store object. Does not commit to the db.
126
126
    """
127
 
    passwd = hashlib.md5(uuid.uuid4().bytes).hexdigest()
 
127
    passwd = md5.new(uuid.uuid4().bytes).digest().encode('hex')
128
128
    if os.path.exists(ivle.conf.svn_auth_ivle):
129
129
        create = ""
130
130
    else: