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

« back to all changes in this revision

Viewing changes to scripts/usrmgt-server

  • Committer: drtomc
  • Date: 2008-02-22 03:48:13 UTC
  • Revision ID: svn-v3-trunk0:2b9c9e99-6f39-0410-b283-7f802c844ae2:trunk:541
Implement a vege algorithm for allocating unix uids: rnd.

Show diffs side-by-side

added added

removed removed

Lines of Context:
67
67
    # FIXME: the IVLE server must check that an admin is doing this!
68
68
 
69
69
    if 'uid' not in props or props['uid'] is None:
70
 
        raise NotImplementedError, "No algorithm for creating uids yet!"
 
70
        # For the time being, just choose a random unixid.
 
71
        # This may result in duplicates, but the unixid is essentially
 
72
        # a monitoring/logging convenience only. Oh, and dups could kill
 
73
        # each other. <sigh>
 
74
        props['uid'] = random.randrange(5000,10000)
 
75
        # raise NotImplementedError, "No algorithm for creating uids yet!"
71
76
        # uid = invent-uid
72
77
        # props['uid'] = uid
73
78