Index: openacs-4/packages/dotlrn/tcl/dotlrn-security-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/tcl/dotlrn-security-procs.tcl,v diff -u -r1.27 -r1.28 --- openacs-4/packages/dotlrn/tcl/dotlrn-security-procs.tcl 8 Mar 2002 00:27:05 -0000 1.27 +++ openacs-4/packages/dotlrn/tcl/dotlrn-security-procs.tcl 13 Mar 2002 06:14:09 -0000 1.28 @@ -21,6 +21,19 @@ namespace eval dotlrn { + ad_proc -public generate_key { + {-name:required} + } { + Generate a key from a name. Uses a concatination of the + name and nexval of the acs_oid sequence. To generate a + globally unique key that can be used in urls. + + FIXME : this is abuse of the sequence, add sequence for this in dotlrn + } { + regsub -all {\W+} $name "" name + return "$name-[db_nextval acs_object_id_seq]" + } + ad_proc -private do_abort {} { do an abort if security violation } {