You can subscribe to this list here.
2007 |
Jan
|
Feb
(23) |
Mar
(4) |
Apr
(60) |
May
(80) |
Jun
(24) |
Jul
(12) |
Aug
(12) |
Sep
(27) |
Oct
(59) |
Nov
(152) |
Dec
(135) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2008 |
Jan
(19) |
Feb
(41) |
Mar
(8) |
Apr
(12) |
May
(14) |
Jun
(8) |
Jul
(23) |
Aug
(3) |
Sep
(1) |
Oct
|
Nov
(2) |
Dec
(1) |
2009 |
Jan
(1) |
Feb
(8) |
Mar
(6) |
Apr
(9) |
May
(2) |
Jun
|
Jul
(2) |
Aug
(2) |
Sep
(9) |
Oct
|
Nov
(3) |
Dec
|
2010 |
Jan
(2) |
Feb
(4) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
From: Davor O. <do...@us...> - 2008-11-29 00:12:33
|
Update of /cvsroot/hcoop/misc/scripts In directory 23jxhf1.ch3.sourceforge.com:/tmp/cvs-serv18841 Modified Files: freeze Log Message: * Fix error where domtool-rmuser was operating on user domtool instead of the actual user, in the freeze script Index: freeze =================================================================== RCS file: /cvsroot/hcoop/misc/scripts/freeze,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** freeze 24 Sep 2008 15:03:26 -0000 1.2 --- freeze 29 Nov 2008 00:11:58 -0000 1.3 *************** *** 286,294 **** } ! if (!DRY) { ! system("domtool-rmuser $_") ! } else { ! warn qq|system("domtool-rmuser $_")\n| ! } push @{ $$store{$u}{modules} }, 'domtool'; --- 286,294 ---- } ! if (!DRY) { ! system("domtool-rmuser $u") ! } else { ! warn qq|system("domtool-rmuser $u")\n| ! } push @{ $$store{$u}{modules} }, 'domtool'; *************** *** 296,304 **** elsif ($a =~ /^u/i) { ! if (!DRY) { ! system("domtool-adduser $_") ! } else { ! warn qq|system("domtool-adduser $_")\n| ! } for ( @{ $$store{$u}{domains} } ) { --- 296,304 ---- elsif ($a =~ /^u/i) { ! if (!DRY) { ! system("domtool-adduser $u") ! } else { ! warn qq|system("domtool-adduser $u")\n| ! } for ( @{ $$store{$u}{domains} } ) { |
From: Adam C. <ad...@us...> - 2008-11-24 14:08:41
|
Update of /cvsroot/hcoop/domtool2/src In directory 23jxhf1.ch3.sourceforge.com:/tmp/cvs-serv25505/src Modified Files: main.sml Log Message: Print on start of mysql-fixperms in domtool-server Index: main.sml =================================================================== RCS file: /cvsroot/hcoop/domtool2/src/main.sml,v retrieving revision 1.106 retrieving revision 1.107 diff -C2 -d -r1.106 -r1.107 *** main.sml 10 Jul 2008 23:38:53 -0000 1.106 --- main.sml 24 Nov 2008 14:08:35 -0000 1.107 *************** *** 1556,1567 **** | MsgMysqlFixperms => ! doIt (fn () => if OS.Process.isSuccess ! (OS.Process.system "/usr/bin/sudo -H /afs/hcoop.net/common/etc/scripts/mysql-grant-table-drop") then ! ("Requested mysql-fixperms", ! NONE) else ("Requested mysql-fixperms, but execution failed!", SOME "Script execution failed.")) ! (fn () => ()) | MsgDescribe dom => --- 1556,1568 ---- | MsgMysqlFixperms => ! (print "Starting mysql-fixperms\n"; ! doIt (fn () => if OS.Process.isSuccess ! (OS.Process.system "/usr/bin/sudo -H /afs/hcoop.net/common/etc/scripts/mysql-grant-table-drop") then ! ("Requested mysql-fixperms", ! NONE) else ("Requested mysql-fixperms, but execution failed!", SOME "Script execution failed.")) ! (fn () => ())) | MsgDescribe dom => |
From: Adam C. <ad...@us...> - 2008-09-27 14:32:54
|
Update of /cvsroot/hcoop/portal In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv527 Modified Files: ip.mlt Log Message: IP address instructions Index: ip.mlt =================================================================== RCS file: /cvsroot/hcoop/portal/ip.mlt,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** ip.mlt 19 Jan 2008 20:57:32 -0000 1.3 --- ip.mlt 27 Sep 2008 14:32:43 -0000 1.4 *************** *** 39,43 **** <a href="ip?mod=<% #id req %>">[Modify]</a> <a href="ip?del=<% #id req %>">[Delete]</a><br> ! To install, run: <i>tell adamc what text to put here</i>. <% end %> --- 39,57 ---- <a href="ip?mod=<% #id req %>">[Modify]</a> <a href="ip?del=<% #id req %>">[Delete]</a><br> ! To install: <ol> ! <li> Choose a new IP address <tt>69.90.123.<i>NNN</i></tt> from those available.</li> ! <li> Add new entry to <tt>/etc/network/interfaces</tt> on mire, where <tt><i>N</i></tt> is some incremented number. ! <blockquote><pre>auto eth0:N ! iface eth0:N inet static ! address 69.90.123.NNN ! netmask 255.255.255.224 ! network 69.90.123.64 ! </pre></blockquote></li> ! <li> Edit <tt>/etc/apache2/ports.conf</tt> and add the following lines: ! <blockquote><pre>Listen 69.90.123.NNN:80 ! Listen 69.90.123.NNN:443</pre></blockquote></li> ! <li> Run <tt>ifup eth0:<i>N</i></tt>. ! <li> Restart Apache with <tt>/etc/init.d/apache2 restart</tt>.</li> ! </ol> <% end %> |
From: Adam C. <ad...@us...> - 2008-08-14 13:58:35
|
Update of /cvsroot/hcoop/domtool2/src/plugins In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv9451/src/plugins Modified Files: bind.sml Log Message: Stop warning about silly DNS directives Index: bind.sml =================================================================== RCS file: /cvsroot/hcoop/domtool2/src/plugins/bind.sml,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** bind.sml 14 Aug 2008 13:07:25 -0000 1.21 --- bind.sml 14 Aug 2008 13:58:32 -0000 1.22 *************** *** 112,117 **** fun writeRecord (evs, r) = case !dns of ! NONE => print ("Warning: DNS directive for " ^ Domain.currentDomain () ! ^ " ignored because no master DNS server is configured for this domain\n") | SOME files => let --- 112,117 ---- fun writeRecord (evs, r) = case !dns of ! NONE => () (* print ("Warning: DNS directive for " ^ Domain.currentDomain () ! ^ " ignored because no master DNS server is configured for this domain\n") *) | SOME files => let |
From: Adam C. <ad...@us...> - 2008-08-14 13:07:31
|
Update of /cvsroot/hcoop/domtool2/src/plugins In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv20513/src/plugins Modified Files: alias.sml bind.sml exim.sml mailman.sml Log Message: Change some node filenames to avoid clashes with subdomains Index: mailman.sml =================================================================== RCS file: /cvsroot/hcoop/domtool2/src/plugins/mailman.sml,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** mailman.sml 5 Dec 2007 01:58:20 -0000 1.13 --- mailman.sml 14 Aug 2008 13:07:25 -0000 1.14 *************** *** 70,74 **** let val {write, writeDom, close} = Domain.domainsFile {node = Config.Mailman.node, ! name = "mailman"} in write "\t'"; --- 70,74 ---- let val {write, writeDom, close} = Domain.domainsFile {node = Config.Mailman.node, ! name = "mailman.conf"} in write "\t'"; *************** *** 176,180 **** in case #file spl of ! "mailman" => mailmanChanged := true | _ => () end) --- 176,180 ---- in case #file spl of ! "mailman.conf" => mailmanChanged := true | _ => () end) *************** *** 182,188 **** val () = Slave.registerPostHandler (fn () => if !mailmanChanged then ! (Slave.concatTo (fn s => s = "mailman") Config.Mailman.mapFile; ! Slave.enumerateTo (fn s => s = "mailman") ":" Config.Mailman.handleDomains; Slave.shellF ([Config.Mailman.reload], --- 182,188 ---- val () = Slave.registerPostHandler (fn () => if !mailmanChanged then ! (Slave.concatTo (fn s => s = "mailman.conf") Config.Mailman.mapFile; ! Slave.enumerateTo (fn s => s = "mailman.conf") ":" Config.Mailman.handleDomains; Slave.shellF ([Config.Mailman.reload], *************** *** 192,196 **** val () = Domain.registerDescriber (Domain.considerAll ! [Domain.Filename {filename = "mailman", heading = "Mailman web host mapping:", showEmpty = false}]) --- 192,196 ---- val () = Domain.registerDescriber (Domain.considerAll ! [Domain.Filename {filename = "mailman.conf", heading = "Mailman web host mapping:", showEmpty = false}]) Index: bind.sml =================================================================== RCS file: /cvsroot/hcoop/domtool2/src/plugins/bind.sml,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** bind.sml 24 Feb 2008 15:50:25 -0000 1.20 --- bind.sml 14 Aug 2008 13:07:25 -0000 1.21 *************** *** 36,40 **** val _ = Domain.registerBefore (fn _ => dns := Option.map (fn node => Domain.domainsFile {node = node, ! name = "dns"}) (Domain.dnsMaster ())) --- 36,40 ---- val _ = Domain.registerBefore (fn _ => dns := Option.map (fn node => Domain.domainsFile {node = node, ! name = "dns.conf"}) (Domain.dnsMaster ())) *************** *** 245,249 **** let val inf = TextIO.openIn (OS.Path.joinDirFile {dir = #dir fs, ! file = "soa"}) val kind = readLine inf val ttl = readILine inf --- 245,249 ---- let val inf = TextIO.openIn (OS.Path.joinDirFile {dir = #dir fs, ! file = "soa.conf"}) val kind = readLine inf val ttl = readILine inf *************** *** 293,297 **** val dns = OS.Path.joinDirFile {dir = #dir fs, ! file = "dns"} val fname = OS.Path.joinBaseExt {base = #domain fs, --- 293,297 ---- val dns = OS.Path.joinDirFile {dir = #dir fs, ! file = "dns.conf"} val fname = OS.Path.joinBaseExt {base = #domain fs, *************** *** 330,335 **** in case file of ! "soa" => dnsChanged () ! | "dns" => dnsChanged () | "named.conf" => namedChanged := true | _ => () --- 330,335 ---- in case file of ! "soa.conf" => dnsChanged () ! | "dns.conf" => dnsChanged () | "named.conf" => namedChanged := true | _ => () *************** *** 355,359 **** heading = "named.conf addition:", showEmpty = false}, ! Domain.Filename {filename = "dns", heading = "DNS zonefile contents:", showEmpty = false}]) --- 355,359 ---- heading = "named.conf addition:", showEmpty = false}, ! Domain.Filename {filename = "dns.conf", heading = "DNS zonefile contents:", showEmpty = false}]) Index: alias.sml =================================================================== RCS file: /cvsroot/hcoop/domtool2/src/plugins/alias.sml,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** alias.sml 1 Jan 2008 22:19:27 -0000 1.6 --- alias.sml 14 Aug 2008 13:07:24 -0000 1.7 *************** *** 57,61 **** val _ = Domain.registerBefore ! (fn _ => (aliases := openInAll "aliases"; reopenAliasesD ())) --- 57,61 ---- val _ = Domain.registerBefore ! (fn _ => (aliases := openInAll "aliases.base"; reopenAliasesD ())) Index: exim.sml =================================================================== RCS file: /cvsroot/hcoop/domtool2/src/plugins/exim.sml,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** exim.sml 20 Nov 2007 00:25:56 -0000 1.10 --- exim.sml 14 Aug 2008 13:07:25 -0000 1.11 *************** *** 43,51 **** val spl = OS.Path.splitDirFile (#file fs) in ! if #file spl = "aliases" then aliasesChanged := true else if #file spl = "aliases.default" then aliasesDefaultChanged := true ! else if #file spl = "mail" then hostsChanged := true else if #file spl = "mail.relay" then --- 43,51 ---- val spl = OS.Path.splitDirFile (#file fs) in ! if #file spl = "aliases.base" then aliasesChanged := true else if #file spl = "aliases.default" then aliasesDefaultChanged := true ! else if #file spl = "mail.handle" then hostsChanged := true else if #file spl = "mail.relay" then *************** *** 58,62 **** (fn () => (if !aliasesChanged then ! Slave.concatTo (fn s => s = "aliases") Config.Exim.aliases else (); --- 58,62 ---- (fn () => (if !aliasesChanged then ! Slave.concatTo (fn s => s = "aliases.base") Config.Exim.aliases else (); *************** *** 66,70 **** (); if !hostsChanged then ! Slave.enumerateTo (fn s => s = "mail") ":" Config.Exim.handleDomains else (); --- 66,70 ---- (); if !hostsChanged then ! Slave.enumerateTo (fn s => s = "mail.handle") ":" Config.Exim.handleDomains else (); *************** *** 88,92 **** app (fn node => #close (Domain.domainsFile {node = node, ! name = "mail"}) ()) nodes end) --- 88,92 ---- app (fn node => #close (Domain.domainsFile {node = node, ! name = "mail.handle"}) ()) nodes end) *************** *** 102,106 **** val () = Domain.registerDescriber (Domain.considerAll ! [Domain.Filename {filename = "aliases", heading = "E-mail aliases:", showEmpty = false}, --- 102,106 ---- val () = Domain.registerDescriber (Domain.considerAll ! [Domain.Filename {filename = "aliases.base", heading = "E-mail aliases:", showEmpty = false}, *************** *** 108,112 **** heading = "Default e-mail alias:", showEmpty = false}, ! Domain.Filename {filename = "mail", heading = "E-mail handling is on.", showEmpty = true}, --- 108,112 ---- heading = "Default e-mail alias:", showEmpty = false}, ! Domain.Filename {filename = "mail.handle", heading = "E-mail handling is on.", showEmpty = true}, |
From: Adam C. <ad...@us...> - 2008-08-14 13:07:30
|
Update of /cvsroot/hcoop/domtool2/src In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv20513/src Modified Files: domain.sml Log Message: Change some node filenames to avoid clashes with subdomains Index: domain.sml =================================================================== RCS file: /cvsroot/hcoop/domtool2/src/domain.sml,v retrieving revision 1.67 retrieving revision 1.68 diff -C2 -d -r1.67 -r1.68 *** domain.sml 15 Jul 2008 14:58:54 -0000 1.67 --- domain.sml 14 Aug 2008 13:07:24 -0000 1.68 *************** *** 610,614 **** fun saveSoa (kind, soa : soa) node = let ! val {write, writeDom, close} = domainsFile {node = node, name = "soa"} in write kind; --- 610,614 ---- fun saveSoa (kind, soa : soa) node = let ! val {write, writeDom, close} = domainsFile {node = node, name = "soa.conf"} in write kind; *************** *** 980,984 **** end ! val () = registerDescriber (considerAll [Filename {filename = "soa", heading = "DNS SOA:", showEmpty = false}]) --- 980,984 ---- end ! val () = registerDescriber (considerAll [Filename {filename = "soa.conf", heading = "DNS SOA:", showEmpty = false}]) |
From: Adam C. <ad...@us...> - 2008-07-30 12:40:30
|
Update of /cvsroot/hcoop/portal In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv22943 Modified Files: welcome.txt Log Message: Add a note about no account existing yet in welcome.txt Index: welcome.txt =================================================================== RCS file: /cvsroot/hcoop/portal/welcome.txt,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** welcome.txt 14 May 2008 17:00:12 -0000 1.6 --- welcome.txt 30 Jul 2008 12:40:14 -0000 1.7 *************** *** 6,11 **** application. Welcome to our family! :-) ! You should now read this wiki page, which describes how we can complete ! your joining process: http://wiki.hcoop.net/MemberManual/GettingStarted/NewMember --- 6,12 ---- application. Welcome to our family! :-) ! You do not have an HCoop account yet and will not be able to log in ! anywhere. You should now read this wiki page, which describes how we ! can complete your joining process: http://wiki.hcoop.net/MemberManual/GettingStarted/NewMember |
From: Adam C. <ad...@us...> - 2008-07-29 14:55:34
|
Update of /cvsroot/hcoop/portal In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv16974 Modified Files: app.sml Log Message: Remove UNIX password files when accounts are marked created Index: app.sml =================================================================== RCS file: /cvsroot/hcoop/portal/app.sml,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** app.sml 1 Apr 2008 18:17:38 -0000 1.15 --- app.sml 29 Jul 2008 14:55:30 -0000 1.16 *************** *** 136,142 **** fun add app = ! ignore (C.dml (getDb ()) ($`UPDATE MemberApp ! SET status = 4 ! WHERE id = ^(C.intToSql app)`)) fun welcome app = --- 136,147 ---- fun add app = ! let ! val appR = lookupApp app ! in ! ignore (C.dml (getDb ()) ($`UPDATE MemberApp ! SET status = 4 ! WHERE id = ^(C.intToSql app)`)); ! OS.FileSys.remove (Config.passwordFiles ^ #name appR) ! end fun welcome app = |
From: Davor O. <do...@us...> - 2008-07-27 18:28:59
|
Update of /cvsroot/hcoop/misc/scripts In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv31942 Added Files: freeze frozen_shell Log Message: * Commit frozen_shell * Commit working freeze script --- NEW FILE: frozen_shell --- #!/bin/sh echo " Please pay your HCoop dues to have your access restored. All information on making a payment is available on our Members Portal, https://members.hcoop.net/ Contact HCoop system administrators at ad...@hc... if you cannot access the Portal. Thank you, HCoop "; exit 0; --- NEW FILE: freeze --- #!/usr/bin/perl # # Purpose: freeze user (cancel user services except email), or unfreeze user. # # Usage (RUN AS _ADMIN USER ON DELEUZE WITHOUT SUDO): # # Display frozen users or details for one user (one user implies -verbose): # freeze [user], OR # freeze [ --action list | -a ] [--verbose | -v] [user] # # Freeze user: # freeze -a f user # # Unfreeze: # freeze -a u user # # # How it works: # # Script invokes a list of modules, where each module knows how to # implement and unimplement a specific restriction. Implemented modules # should be listed in @modules array or they won't get called. Admin # can override list of modules with --modules=one,two,three. # # Modules execute in the order as specified for freeze, and in reverse # order for unfreeze. # # Module gets called as &module($action, $user) . The proper way to # test for which action is requested is as shown below. (Note that # module adds or removes itself to the list of modules that ran on the user). # # if ($a =~ /^f/i) { # ... freeze ... # push @{ $$store{$u}{modules} }, 'MODULE'; # } elsif ($a =~ /^u/i) { # ... unfreeze ... # @{ $$store{$u}{modules} } = grep {!/^MODULE$/} @{ $$store{$u}{modules} }; # } # # Also each system-modifying action should be wrapped in if (!DRY) as shown: # # if (!DRY) { # system(qq{SOME COMMAND}) # } else { # warn qq|SOME COMMAND| # } # # User is valid system username, and user's getent entry is prepared and # retrievable through @user array, should you need some of its info. # # Module can save all persistent data to $$store{$user}{$modulename}. For # example, after cron module removes user from all cron.allows, it # registers the machines where user was removed to # @{ $$store{$u}{cron} }, so that it can revert it back if user is # unfreezed. # # Module 'record' creates or deletes initial user entry in $$store. # If you create a new module that will use the store, announce its # hash key by creating it empty in record(). # # For additional detail, here's how the stored hash might look like: # # # $store = { # user1 => { # date => 'Sun Jun 29 18:45:43 CEST 2008', # getent => [qw/docelic 1000 1000 DavorOcelic /home/docelic /bin/bash] # # modules => [qw/login domtool cron slay/], # (modules that ran) # domains => [qw/spinlock.hr test.hr/], # (domains that were removed) # cron => [qw/mire/], # (hosts where cron.allow entry was removed) # }, # user2 => { # ... # }, # ... # ... # ... # } # # # Wiki page relating to this script is http://wiki.hcoop.net/MemberFreezing # # Davor Ocelic, do...@hc..., Sun Jun 29 18:41:02 CEST 2008 # # use warnings; use strict; use Storable qw/lock_nstore lock_retrieve/; use Getopt::Long qw/GetOptions/; use constant DEBUG => 1; use constant DRY => 0; use constant STORE => "/var/tmp/frozen/cache"; use constant DEFAULT_SHELL => '/bin/bash'; use constant FROZEN_SHELL => '/afs/hcoop.net/common/etc/scripts/frozen_shell'; use constant PUBLIC_ACCESS => (qw/mire/); use constant RUN_SERVER => 'deleuze'; my $store = {}; # cached info my $action = 'list'; # list, freeze, unfreeze my $verbose = 0; # 0/1 (print which modules were applied to user in freezing) my $force = 0; # 0/1 (force action even if user already freezed/unfreezed) my $user; # who to freeze/unfreeze my @user; # getent passwd entry for user my $modules; # list of freeze/unfreeze actions to take my @modules; # modules, possibly overriden by split /,\s+/, $modules # Keep modules listed in order of application, honoring possible dependencies. @modules = (qw/record login domtool slay/); unless ( GetOptions ( 'do|d|a=s' => \$action, 'verbose|v!' => \$verbose, 'force!' => \$force, 'modules|m=s' => \$modules, )) { die "Error parsing options: $!\n" } $user = shift ; if ( $> == 0 or $< == 0 ) { die "Run script under admin account without sudo.\n"; } if ( -e STORE ) { $store = lock_retrieve(STORE); } else { warn "No '" . STORE . "', skipping load.\n"; } if ( `hostname` ne RUN_SERVER . "\n" ) { die "Please run script on " . RUN_SERVER . "\n"; } if ( $action =~ /^l/i ) { while (my ($k,$v) = each %$store ) { if (! $user or $user eq $k ) { print "$k $$v{date}\n"; print " @{$$v{modules}}\n" if $verbose or $user; } } exit 0; } $user or die "Must specify user to freeze/unfreeze. Exiting.\n"; $user =~ /^[a-z0-9]+$/ or die "Invalid username (not [a-z0-9]+).\n"; @user = split(/:/, `getent passwd $user`); @user or die "No such user? (getent passwd USER empty.)\n"; chomp $user[$#user]; if ( $action !~ /^[fu]/i ) { warn "Unknown action: use -a [list (l)|freeze (f)|unfreeze (u)]\n"; } if ( $action =~ /^f/i ) { if ( exists $$store{$user} ) { warn "User already frozen since $$store{$user}{date}.\n"; if (! $force) { die "Exiting.\n"; } } } elsif ( $action =~ /^u/i ) { if (! exists $$store{$user} ) { warn "User not frozen in the first place.\n"; if (! $force) { die "Exiting.\n"; } } } else { warn "How did you get through?\n"; die; } if ($modules) { @modules = split /[,\s+]/, $modules; } for ( $action =~ /^u/i ? reverse @modules : @modules ) { no strict 'refs'; print "Module: $_\n"; &{ $_ }($action, $user); } lock_nstore $store, STORE; ########################################################################### # Helpers below # GETENT (available to modules automatically in @user): # 0 1 2 3 4 5 6 # docelic:x:10235:65534:docelic:/afs/hcoop.net/user/d/do/docelic:/bin/bash sub record { my ($a, $u) = @_; $a =~ /^f/i and $$store{$u} = { date => scalar localtime, getent => [ @user ], modules => [], domains => [], cron => [], }; $a =~ /^u/i and delete $$store{$u}; } sub login { my ($a, $u) = @_; if ($a =~ /^f/i) { if ( $user[6] ne DEFAULT_SHELL ) { $$store{$u}{shell} = $user[6] unless $user[6] eq FROZEN_SHELL; } if ( -e "$user[5]/.loginshell" ) { if (!DRY) { unlink "$user[5]/.loginshell" or warn "unlink: $!" } else { warn qq{unlink $user[5]/.loginshell\n}; } } if (!DRY) { symlink FROZEN_SHELL, "$user[5]/.loginshell" or warn "symlink: $!"; } else { warn qq{symlink FROZEN_SHELL, "$user[5]/.loginshell"\n} } push @{ $$store{$u}{modules} }, 'login'; if ( -x "/usr/sbin/nscd" ) { system("sudo /usr/sbin/nscd -i passwd") }; } elsif ($a =~ /^u/i) { if ( $$store{$u}{shell}) { if ( -l "$user[5]/.loginshell" or -e "$user[5]/.loginshell" ) { if (!DRY) { system("rm '$user[5]/.loginshell'"); } else { warn qq{system("rm '$user[5]/.loginshell'")\n}; } } if (!DRY) { symlink($$store{$u}{shell}, "$user[5]/.loginshell") or warn "symlink: $!"; } else { warn qq|symlink($$store{$u}{shell}, "$user[5]/.loginshell")\n|; } } @{ $$store{$u}{modules} } = grep {!/^login$/} @{ $$store{$u}{modules} }; if ( -x "/usr/sbin/nscd" ) { system("sudo /usr/sbin/nscd -i passwd") }; } } sub domtool { my ($a, $u) = @_; # XXX handle all types of domtool privs, not just domains # XXX how to restart services after that? if ($a =~ /^f/i) { my $domains = `domtool-admin perms $u | grep '^domain: '`; chomp $domains; my @domains = split / +/, $domains; for (@domains) { push @{ $$store{$u}{domains} }, $_; if (!DRY) { system("domtool-admin rmdom $_") } else { warn qq|system("domtool-admin rmdom $_")\n| } } if (!DRY) { system("domtool-rmuser $_") } else { warn qq|system("domtool-rmuser $_")\n| } push @{ $$store{$u}{modules} }, 'domtool'; } elsif ($a =~ /^u/i) { if (!DRY) { system("domtool-adduser $_") } else { warn qq|system("domtool-adduser $_")\n| } for ( @{ $$store{$u}{domains} } ) { if (!DRY) { system("domtool-admin grant $u domain $_") } else { warn qq|system("domtool-admin grant $u domain $_")\n| } } @{ $$store{$u}{modules} } = grep {!/^domtool$/} @{ $$store{$u}{modules} }; } } sub cron { my ($a, $u) = @_; if ($a =~ /^f/i) { for ( PUBLIC_ACCESS ) { if ( qx{ssh -K $_ grep -E '^$u\$' /etc/cron.allow }) { push @{ $$store{$u}{cron} }, $_; if (!DRY) { qx{ssh -K $_ perl -ni -e 'print unless /^\$/' /etc/cron.allow } } else { warn qq{ssh -K $_ perl -ni -e 'print unless /^\$/' /etc/cron.allow\n} } } } push @{ $$store{$u}{modules} }, 'cron'; } elsif ($a =~ /^u/i) { for ( @{ $$store{$u}{cron} } ) { if (!DRY) { qx{ssh -K $_ sh -c 'echo $u >> /etc/cron.allow'}; } else { warn qq{ssh -K $_ sh -c 'echo $u >> /etc/cron.allow'\n}; } } @{ $$store{$u}{modules} } = grep {!/^cron$/} @{ $$store{$u}{modules} }; } } sub slay { my ($a, $u) = @_; if ($a =~ /^f/i) { for ( PUBLIC_ACCESS ) { if (!DRY) { qx{ssh -K $_ sudo slay $u}; sleep 5; qx{ssh -K $_ sudo slay -9 $u}; } else { warn qq|ssh -K $_ sudo slay $u; sleep 5; ssh -K $_ sudo slay -9 $u\n| } } push @{ $$store{$u}{modules} }, 'slay'; } elsif ($a =~ /^f/i) { @{ $$store{$u}{modules} } = grep {!/^slay$/} @{ $$store{$u}{modules} }; } } |
From: Adam C. <ad...@us...> - 2008-07-26 14:20:42
|
Update of /cvsroot/hcoop/domtool2/src/plugins In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv7041/src/plugins Modified Files: apache.sml Log Message: Output suPHP_UserGroup Index: apache.sml =================================================================== RCS file: /cvsroot/hcoop/domtool2/src/plugins/apache.sml,v retrieving revision 1.82 retrieving revision 1.83 diff -C2 -d -r1.82 -r1.83 *** apache.sml 15 Jul 2008 15:45:36 -0000 1.82 --- apache.sml 26 Jul 2008 14:20:37 -0000 1.83 *************** *** 522,525 **** --- 522,529 ---- TextIO.output (file, user); TextIO.output (file, " "); + TextIO.output (file, group); + TextIO.output (file, "\n\tsuPHP_UserGroup "); + TextIO.output (file, user); + TextIO.output (file, " "); TextIO.output (file, group)) else |
From: Adam C. <ad...@us...> - 2008-07-16 00:06:46
|
Update of /cvsroot/hcoop/domtool2/scripts In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv18067/scripts Modified Files: domtool-addcert Log Message: domtool-addcert handles inability to set an ACL entry Index: domtool-addcert =================================================================== RCS file: /cvsroot/hcoop/domtool2/scripts/domtool-addcert,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** domtool-addcert 15 Jul 2008 20:11:28 -0000 1.4 --- domtool-addcert 16 Jul 2008 00:06:43 -0000 1.5 *************** *** 17,21 **** openssl genrsa -out $KEYFILE chown -R domtool.domtool $KEYDIR ! fs sa $KEYDIR $USER read echo "." >$KEYIN echo "." >>$KEYIN --- 17,21 ---- openssl genrsa -out $KEYFILE chown -R domtool.domtool $KEYDIR ! fs sa $KEYDIR $USER read || echo This must be a server principal. echo "." >$KEYIN echo "." >>$KEYIN |
From: Adam C. <ad...@us...> - 2008-07-15 20:11:31
|
Update of /cvsroot/hcoop/domtool2/scripts In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv16718/scripts Modified Files: domtool-addcert Added Files: domtool-readdcerts Removed Files: domtool-addcert-daemon Log Message: domtool-readdcerts --- domtool-addcert-daemon DELETED --- --- NEW FILE: domtool-readdcerts --- #!/bin/bash for i in `ls /afs/hcoop.net/common/etc/domtool/keys`; do /usr/local/bin/domtool-addcert $i done; Index: domtool-addcert =================================================================== RCS file: /cvsroot/hcoop/domtool2/scripts/domtool-addcert,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** domtool-addcert 15 Feb 2008 02:03:30 -0000 1.3 --- domtool-addcert 15 Jul 2008 20:11:28 -0000 1.4 *************** *** 7,18 **** fi ! KEYDIR=/afs/hcoop.net/common/etc/domtool/keys/$1 KEYFILE=$KEYDIR/key.pem ! CERTFILE=/afs/hcoop.net/common/etc/domtool/certs/$1.pem NEWREQ=~/.newreq.pem NEW=~/.new.pem KEYIN=~/.keyin ! mkdir -p $KEYDIR openssl genrsa -out $KEYFILE chown -R domtool.domtool $KEYDIR --- 7,18 ---- fi ! KEYDIR=/afs/hcoop.net/common/etc/domtool/keys/$USER KEYFILE=$KEYDIR/key.pem ! CERTFILE=/afs/hcoop.net/common/etc/domtool/certs/$USER.pem NEWREQ=~/.newreq.pem NEW=~/.new.pem KEYIN=~/.keyin ! mkdir $KEYDIR || echo Key directory already exists. openssl genrsa -out $KEYFILE chown -R domtool.domtool $KEYDIR |
From: Adam C. <ad...@us...> - 2008-07-15 20:11:31
|
Update of /cvsroot/hcoop/domtool2 In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv16718 Modified Files: Makefile Log Message: domtool-readdcerts Index: Makefile =================================================================== RCS file: /cvsroot/hcoop/domtool2/Makefile,v retrieving revision 1.45 retrieving revision 1.46 diff -C2 -d -r1.45 -r1.46 *** Makefile 15 Jul 2008 19:47:14 -0000 1.45 --- Makefile 15 Jul 2008 20:11:28 -0000 1.46 *************** *** 189,193 **** cp scripts/domtool-adduser /usr/local/bin/ cp scripts/domtool-addcert /usr/local/bin/ ! cp scripts/domtool-addcert-daemon /usr/local/bin/ cp scripts/domtool-addacl /usr/local/bin/ cp scripts/domtool-rmuser /usr/local/bin/ --- 189,193 ---- cp scripts/domtool-adduser /usr/local/bin/ cp scripts/domtool-addcert /usr/local/bin/ ! cp scripts/domtool-readdcerts /usr/local/bin/ cp scripts/domtool-addacl /usr/local/bin/ cp scripts/domtool-rmuser /usr/local/bin/ |
From: Adam C. <ad...@us...> - 2008-07-15 19:47:20
|
Update of /cvsroot/hcoop/domtool2/src/tail In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv6489/src/tail Modified Files: tail.sml Log Message: Make domtool-tail actually work Index: tail.sml =================================================================== RCS file: /cvsroot/hcoop/domtool2/src/tail/tail.sml,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** tail.sml 15 Jul 2008 19:39:29 -0000 1.1 --- tail.sml 15 Jul 2008 19:47:14 -0000 1.2 *************** *** 38,47 **** in case args of ! [vhost] => let val uid = Posix.ProcEnv.getuid () val uname = Posix.SysDB.Passwd.name (Posix.SysDB.getpwuid uid) ! val proc = Unix.execute ("/usr/local/bin/domtool-admin-sudo-noisy", ["perms", uname]) val inf = Unix.textInstreamOf proc --- 38,54 ---- in case args of ! [vhost, kind] => let + val () = case kind of + "access" => () + | "error" => () + | "rewrite" => () + | _ => (print "Unsupported logfile kind. Use 'access', 'error', or 'rewrite'.\n"; + OS.Process.exit OS.Process.failure) + val uid = Posix.ProcEnv.getuid () val uname = Posix.SysDB.Passwd.name (Posix.SysDB.getpwuid uid) ! val proc = Unix.execute ("/usr/local/bin/domtool-admin", ["perms", uname]) val inf = Unix.textInstreamOf proc *************** *** 74,78 **** ^ hostname () ^ "/" ! ^ vhost] val tailArgs = --- 81,88 ---- ^ hostname () ^ "/" ! ^ vhost ! ^ "/" ! ^ kind ! ^ ".log"] val tailArgs = |
From: Adam C. <ad...@us...> - 2008-07-15 19:47:20
|
Update of /cvsroot/hcoop/domtool2/scripts In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv6489/scripts Removed Files: domtool-admin-sudo-noisy Log Message: Make domtool-tail actually work --- domtool-admin-sudo-noisy DELETED --- |
From: Adam C. <ad...@us...> - 2008-07-15 19:47:20
|
Update of /cvsroot/hcoop/domtool2 In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv6489 Modified Files: Makefile Log Message: Make domtool-tail actually work Index: Makefile =================================================================== RCS file: /cvsroot/hcoop/domtool2/Makefile,v retrieving revision 1.44 retrieving revision 1.45 diff -C2 -d -r1.44 -r1.45 *** Makefile 15 Jul 2008 19:39:28 -0000 1.44 --- Makefile 15 Jul 2008 19:47:14 -0000 1.45 *************** *** 193,197 **** cp scripts/domtool-rmuser /usr/local/bin/ cp scripts/domtool-admin-sudo /usr/local/bin/ - cp scripts/domtool-admin-sudo-noisy /usr/local/bin/ cp scripts/domtool-server-logged /usr/local/bin/ cp scripts/domtool-slave-logged /usr/local/bin/ --- 193,196 ---- |
From: Adam C. <ad...@us...> - 2008-07-15 19:39:36
|
Update of /cvsroot/hcoop/domtool2 In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv3174 Modified Files: Makefile Log Message: domtool-tail Index: Makefile =================================================================== RCS file: /cvsroot/hcoop/domtool2/Makefile,v retrieving revision 1.43 retrieving revision 1.44 diff -C2 -d -r1.43 -r1.44 *** Makefile 15 Dec 2007 16:54:21 -0000 1.43 --- Makefile 15 Jul 2008 19:39:28 -0000 1.44 *************** *** 16,20 **** mlton: bin/domtool-server bin/domtool-client bin/domtool-slave \ bin/domtool-admin bin/domtool-doc bin/dbtool bin/vmail \ ! bin/smtplog bin/setsa bin/mysql-fixperms bin/webbw smlnj: $(COMMON_DEPS) openssl/smlnj/FFI/libssl.h.cm pcre/smlnj/FFI/libpcre.h.cm \ --- 16,20 ---- mlton: bin/domtool-server bin/domtool-client bin/domtool-slave \ bin/domtool-admin bin/domtool-doc bin/dbtool bin/vmail \ ! bin/smtplog bin/setsa bin/mysql-fixperms bin/webbw bin/domtool-tail smlnj: $(COMMON_DEPS) openssl/smlnj/FFI/libssl.h.cm pcre/smlnj/FFI/libpcre.h.cm \ *************** *** 170,176 **** $(MLTON) -output bin/mysql-fixperms src/mysql-fixperms.mlb ! bin/webbw: $(COMMON_MLTON_DEPS) src/stats/webbw.mlb mlton -output bin/webbw src/stats/webbw.mlb elisp/domtool-tables.el: lib/*.dtl bin/domtool-doc bin/domtool-doc -basis -emacs >$@ --- 170,179 ---- $(MLTON) -output bin/mysql-fixperms src/mysql-fixperms.mlb ! bin/webbw: $(COMMON_MLTON_DEPS) src/stats/webbw.mlb src/stats/*.sml mlton -output bin/webbw src/stats/webbw.mlb + bin/domtool-tail: $(COMMON_MLTON_DEPS) src/tail/tail.mlb src/tail/*.sml + mlton -output bin/domtool-tail src/tail/tail.mlb + elisp/domtool-tables.el: lib/*.dtl bin/domtool-doc bin/domtool-doc -basis -emacs >$@ *************** *** 190,193 **** --- 193,197 ---- cp scripts/domtool-rmuser /usr/local/bin/ cp scripts/domtool-admin-sudo /usr/local/bin/ + cp scripts/domtool-admin-sudo-noisy /usr/local/bin/ cp scripts/domtool-server-logged /usr/local/bin/ cp scripts/domtool-slave-logged /usr/local/bin/ *************** *** 206,209 **** --- 210,215 ---- -cp bin/vmailpasswd /usr/local/bin/ -cp bin/webbw /usr/local/sbin/ + -cp bin/domtool-tail /usr/local/bin/ + -chmod +s /usr/local/bin/domtool-tail cp src/plugins/domtool-postgres /usr/local/sbin/ cp src/plugins/domtool-mysql /usr/local/sbin/ |
From: Adam C. <ad...@us...> - 2008-07-15 19:39:32
|
Update of /cvsroot/hcoop/domtool2/src/tail In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv3174/src/tail Added Files: tail.mlb tail.sml Log Message: domtool-tail --- NEW FILE: tail.sml --- (* HCoop Domtool (http://hcoop.sourceforge.net/) * Copyright (c) 2008, Adam Chlipala * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *) (* Tailing Apache log files (locally) that you are allowed to see *) fun hostname () = let val inf = TextIO.openIn "/etc/hostname" in case TextIO.inputLine inf of NONE => (TextIO.closeIn inf; raise Fail "No line in /etc/hostname") | SOME line => (TextIO.closeIn inf; String.substring (line, 0, size line - 1)) end fun main args = let val (f, args) = foldl (fn (arg, (f, args)) => case arg of "-f" => (true, args) | _ => (f, arg :: args)) (false, []) args val args = rev args in case args of [vhost] => let val uid = Posix.ProcEnv.getuid () val uname = Posix.SysDB.Passwd.name (Posix.SysDB.getpwuid uid) val proc = Unix.execute ("/usr/local/bin/domtool-admin-sudo-noisy", ["perms", uname]) val inf = Unix.textInstreamOf proc fun allowed () = case TextIO.inputLine inf of NONE => [] | SOME line => case String.tokens Char.isSpace line of "domain:" :: domains => domains | _ => allowed () val domains = allowed () fun inDomains d = List.exists (fn s => s = d) domains fun checker pieces = case pieces of [] => false | _ :: pieces => inDomains (String.concatWith "." pieces) orelse checker pieces val tailArgs = ["/var/log/apache2/user/" ^ String.substring (uname, 0, 1) ^ "/" ^ String.substring (uname, 0, 2) ^ "/" ^ uname ^ "/apache/log/" ^ hostname () ^ "/" ^ vhost] val tailArgs = if f then "-f" :: tailArgs else tailArgs in ignore (Unix.reap proc); if inDomains vhost orelse checker (String.fields (fn ch => ch = #".") vhost) then Posix.Process.exec ("/usr/bin/tail", "/usr/bin/tail" :: tailArgs) else (print "You're not authorized to view the logs for that vhost.\n"; OS.Process.exit OS.Process.failure) end | _ => (print "Invalid arguments\n"; OS.Process.exit OS.Process.failure) end val () = main (CommandLine.arguments ()) --- NEW FILE: tail.mlb --- $(SML_LIB)/basis/basis.mlb tail.sml |
From: Adam C. <ad...@us...> - 2008-07-15 19:39:32
|
Update of /cvsroot/hcoop/domtool2/scripts In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv3174/scripts Modified Files: domtool-admin-sudo Added Files: domtool-admin-sudo-noisy Log Message: domtool-tail Index: domtool-admin-sudo =================================================================== RCS file: /cvsroot/hcoop/domtool2/scripts/domtool-admin-sudo,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** domtool-admin-sudo 17 Nov 2007 16:15:03 -0000 1.3 --- domtool-admin-sudo 15 Jul 2008 19:39:28 -0000 1.4 *************** *** 1,2 **** --- 1,4 ---- + #!/usr/bin/pagsh.openafs + kinit -k -t /etc/keytabs/domtool domtool aklog --- NEW FILE: domtool-admin-sudo-noisy --- #!/usr/bin/pagsh.openafs kinit -k -t /etc/keytabs/domtool domtool aklog domtool-admin $* |
From: Adam C. <ad...@us...> - 2008-07-15 19:39:32
|
Update of /cvsroot/hcoop/domtool2/bin In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv3174/bin Modified Files: .cvsignore Log Message: domtool-tail Index: .cvsignore =================================================================== RCS file: /cvsroot/hcoop/domtool2/bin/.cvsignore,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** .cvsignore 9 Dec 2007 21:46:48 -0000 1.13 --- .cvsignore 15 Jul 2008 19:39:28 -0000 1.14 *************** *** 11,13 **** vmailpasswd webbw ! --- 11,13 ---- vmailpasswd webbw ! domtool-tail |
From: Adam C. <ad...@us...> - 2008-07-15 19:38:20
|
Update of /cvsroot/hcoop/domtool2/src/tail In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv2741/src/tail Log Message: Directory /cvsroot/hcoop/domtool2/src/tail added to the repository |
From: Adam C. <ad...@us...> - 2008-07-15 16:32:56
|
Update of /cvsroot/hcoop/portal In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv22320 Modified Files: money.mlt portal.mlt util.sig util.sml Log Message: Links to list all transactions; debit/credit columns Index: util.sml =================================================================== RCS file: /cvsroot/hcoop/portal/util.sml,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** util.sml 18 Feb 2008 17:46:05 -0000 1.17 --- util.sml 15 Jul 2008 16:32:52 -0000 1.18 *************** *** 33,36 **** --- 33,39 ---- fun mult (r1, r2) = real r1 * r2 + fun lt (r1 : real, r2) = r1 < r2 + fun ge (r1 : real, r2) = r1 >= r2 + fun isIdent ch = Char.isLower ch orelse Char.isDigit ch orelse ch = #"-" Index: money.mlt =================================================================== RCS file: /cvsroot/hcoop/portal/money.mlt,v retrieving revision 1.33 retrieving revision 1.34 diff -C2 -d -r1.33 -r1.34 *** money.mlt 15 Jul 2008 16:19:04 -0000 1.33 --- money.mlt 15 Jul 2008 16:32:51 -0000 1.34 *************** *** 664,668 **** <% else %> <a href="?audit=1">Switch to audit view</a><br> ! <% val lookback = case $"lookback" of "" => 20 | lb => Web.stoi lb; @payment [] %> --- 664,668 ---- <% else %> <a href="?audit=1">Switch to audit view</a><br> ! <% val lookback = case $"lookback" of "" => 20 | "inf" => 0 | lb => Web.stoi lb; @payment [] %> *************** *** 670,686 **** <form> ! Show <input name="lookback" size="5" value="<% lookback %>"> most recent transactions. <input type="submit" value="Show"> </form> ! <% ref running = showBal %> <table> ! <tr> <td><b>Date</b></td> <td><b>Description</b></td> <td><b>Amount</b></td> <td><b>Balance</b></td></tr> ! <% foreach (amount, trn) in Money.listUserTransactionsLimit (Init.getUserId (), lookback) do %> ! <tr> <td><% #d trn %></td> <td><a href="money?trn=<% #id trn %>"><% Web.html (#descr trn) %></a></td> <td><% amount %>/<% #amount trn %></td> <td><% running %></tr> <% running := Util.sub (running, amount) end %> </table> <% end --- 670,695 ---- <form> ! Show <input name="lookback" size="5" value="<% iff lookback = 0 then 20 else lookback %>"> most recent transactions. <input type="submit" value="Show"> </form> ! <% ref running = showBal; ! val trans = iff lookback = 0 then ! Money.listUserTransactions (Init.getUserId ()) ! else ! Money.listUserTransactionsLimit (Init.getUserId (), lookback) %> <table> ! <tr> <td><b>Date</b></td> <td><b>Description</b></td> <td><b>Debit</b></td> <td><b>Credit</b></td> <td><b>Balance</b></td></tr> ! <% foreach (amount, trn) in trans do %> ! <tr> <td><% #d trn %></td> <td><a href="money?trn=<% #id trn %>"><% Web.html (#descr trn) %></a></td> ! <td align="right"><% if Util.lt (amount, 0.0) then %><% amount %><% end %></td> ! <td align="right"><% if Util.ge (amount, 0.0) then %><% amount %><% end %></td> <td><% running %></tr> <% running := Util.sub (running, amount) end %> </table> + <% if lookback <> 0 then %> + <a href="?lookback=inf">Show all transactions</a><br> + <% end %> <% end Index: util.sig =================================================================== RCS file: /cvsroot/hcoop/portal/util.sig,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** util.sig 18 Feb 2008 17:46:05 -0000 1.14 --- util.sig 15 Jul 2008 16:32:52 -0000 1.15 *************** *** 19,22 **** --- 19,25 ---- val mult : int * real -> real + val lt : real * real -> bool + val ge : real * real -> bool + val validHost : string -> bool val validDomain : string -> bool Index: portal.mlt =================================================================== RCS file: /cvsroot/hcoop/portal/portal.mlt,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** portal.mlt 15 Jul 2008 16:19:04 -0000 1.21 --- portal.mlt 15 Jul 2008 16:32:52 -0000 1.22 *************** *** 18,21 **** --- 18,22 ---- end %> </table> + <a href="money?lookback=inf">Show all transactions</a><br> <b>Balance: $<% showBal %></b><br> <b>Deposit: $<% deposit %></b> (3 months of dues at the minimal <a href="pledge">pledge level</a>) |
From: Adam C. <ad...@us...> - 2008-07-15 16:19:08
|
Update of /cvsroot/hcoop/portal In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv16662 Modified Files: money.mlt portal.mlt Log Message: Show running balances on transaction summaries Index: money.mlt =================================================================== RCS file: /cvsroot/hcoop/portal/money.mlt,v retrieving revision 1.32 retrieving revision 1.33 diff -C2 -d -r1.32 -r1.33 *** money.mlt 30 Jun 2008 12:26:29 -0000 1.32 --- money.mlt 15 Jul 2008 16:19:04 -0000 1.33 *************** *** 599,605 **** val you = Init.getUser(); val bal = Balance.lookupBalance (#bal you); ! val deposit = Balance.depositAmount (#id bal) %> ! <h3>Your balance: $<% Util.sub (#amount bal, deposit) %><br> Deposit: $<% deposit %></b> (3 months of dues at the minimal <a href="pledge">pledge level</a>)<br> Co-op balance: $<% #amount (Balance.lookupBalance (valOf (Balance.balanceNameToId "hcoop"))) %></h3> --- 599,606 ---- val you = Init.getUser(); val bal = Balance.lookupBalance (#bal you); ! val deposit = Balance.depositAmount (#id bal); ! val showBal = Util.sub (#amount bal, deposit) %> ! <h3>Your balance: $<% showBal %><br> Deposit: $<% deposit %></b> (3 months of dues at the minimal <a href="pledge">pledge level</a>)<br> Co-op balance: $<% #amount (Balance.lookupBalance (valOf (Balance.balanceNameToId "hcoop"))) %></h3> *************** *** 673,681 **** </form> <table> ! <tr> <td><b>Date</b></td> <td><b>Description</b></td> <td><b>Amount</b></td> </tr> <% foreach (amount, trn) in Money.listUserTransactionsLimit (Init.getUserId (), lookback) do %> ! <tr> <td><% #d trn %></td> <td><a href="money?trn=<% #id trn %>"><% Web.html (#descr trn) %></a></td> <td><% amount %>/<% #amount trn %></td> </tr> ! <% end %> </table> --- 674,685 ---- </form> + <% ref running = showBal %> <table> ! <tr> <td><b>Date</b></td> <td><b>Description</b></td> <td><b>Amount</b></td> <td><b>Balance</b></td></tr> <% foreach (amount, trn) in Money.listUserTransactionsLimit (Init.getUserId (), lookback) do %> ! <tr> <td><% #d trn %></td> <td><a href="money?trn=<% #id trn %>"><% Web.html (#descr trn) %></a></td> <td><% amount %>/<% #amount trn %></td> ! <td><% running %></tr> ! <% running := Util.sub (running, amount) ! end %> </table> Index: portal.mlt =================================================================== RCS file: /cvsroot/hcoop/portal/portal.mlt,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** portal.mlt 24 Apr 2008 19:28:07 -0000 1.20 --- portal.mlt 15 Jul 2008 16:19:04 -0000 1.21 *************** *** 2,5 **** --- 2,6 ---- val bal = Balance.lookupBalance (#bal you); val deposit = Balance.depositAmount (#id bal); + val showBal = Util.sub (#amount bal, deposit); @header [] %> *************** *** 8,18 **** <h3><a href="money">Your recent account activity</a></h3> <table> ! <tr> <td><b>Date</b></td> <td><b>Description</b></td> <td><b>Amount</b></td> </tr> <% foreach (amount, trn) in Money.listUserTransactionsLimit (Init.getUserId (), 5) do %> ! <tr> <td><% #d trn %></td> <td><a href="money?trn=<% #id trn %>"><% Web.html (#descr trn) %></a></td> <td><% amount %>/<% #amount trn %></td> </tr> ! <% end %> </table> ! <b>Balance: $<% Util.sub (#amount bal, deposit) %></b><br> <b>Deposit: $<% deposit %></b> (3 months of dues at the minimal <a href="pledge">pledge level</a>) --- 9,22 ---- <h3><a href="money">Your recent account activity</a></h3> + <% ref running = showBal %> <table> ! <tr> <td><b>Date</b></td> <td><b>Description</b></td> <td><b>Amount</b></td> <td><b>Balance</b></td></tr> <% foreach (amount, trn) in Money.listUserTransactionsLimit (Init.getUserId (), 5) do %> ! <tr> <td><% #d trn %></td> <td><a href="money?trn=<% #id trn %>"><% Web.html (#descr trn) %></a></td> <td><% amount %>/<% #amount trn %></td> ! <td><% running %></tr> ! <% running := Util.sub (running, amount) ! end %> </table> ! <b>Balance: $<% showBal %></b><br> <b>Deposit: $<% deposit %></b> (3 months of dues at the minimal <a href="pledge">pledge level</a>) |
From: Adam C. <ad...@us...> - 2008-07-15 16:06:47
|
Update of /cvsroot/hcoop/domtool2/lib In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv2156/lib Modified Files: apache.dtl mod_rewrite.dtl Log Message: FilesMatch directive Index: apache.dtl =================================================================== RCS file: /cvsroot/hcoop/domtool2/lib/apache.dtl,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** apache.dtl 24 Feb 2008 20:53:04 -0000 1.16 --- apache.dtl 15 Jul 2008 15:45:36 -0000 1.17 *************** *** 72,75 **** --- 72,81 ---- respectively.}} + extern type regexp; + {{PCRE regular expression}} + + extern val filesMatch : regexp -> ^Vhost & Location => [Vhost & !Location]; + {{Mark nested configuration to only apply to filenames matching the regexp.}} + extern val serverAliasHost : your_domain_host -> [Vhost]; {{Give an alternate hostname for this vhost.}} Index: mod_rewrite.dtl =================================================================== RCS file: /cvsroot/hcoop/domtool2/lib/mod_rewrite.dtl,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** mod_rewrite.dtl 15 Dec 2007 16:54:21 -0000 1.7 --- mod_rewrite.dtl 15 Jul 2008 15:45:36 -0000 1.8 *************** *** 47,53 **** extern val ornext : mod_rewrite_cond_flag; - extern type regexp; - {{PCRE regular expression}} - extern val rewriteRule : regexp -> no_spaces -> [mod_rewrite_flag] -> [^Vhost]; {{See <a href="http://httpd.apache.org/docs/2.0/mod/mod_rewrite.html#rewriterule">Apache --- 47,50 ---- |
From: Adam C. <ad...@us...> - 2008-07-15 16:06:25
|
Update of /cvsroot/hcoop/domtool2/src/plugins In directory sc8-pr-cvs17.sourceforge.net:/tmp/cvs-serv2156/src/plugins Modified Files: apache.sml Log Message: FilesMatch directive Index: apache.sml =================================================================== RCS file: /cvsroot/hcoop/domtool2/src/plugins/apache.sml,v retrieving revision 1.81 retrieving revision 1.82 diff -C2 -d -r1.81 -r1.82 *** apache.sml 15 Jul 2008 14:31:13 -0000 1.81 --- apache.sml 15 Jul 2008 15:45:36 -0000 1.82 *************** *** 595,598 **** --- 595,607 ---- localRewriteEnabled := false)) + val () = Env.container_one "filesMatch" + ("regexp", Env.string) + (fn prefix => + (write "\t<FilesMatch \""; + write prefix; + write "\">\n"), + fn () => (write "\t</FilesMatch>\n"; + localRewriteEnabled := false)) + fun checkRewrite () = if !inLocal then |