Browse Source

Plan 9 from Bell Labs 2005-01-07

David du Colombier 17 years ago
parent
commit
16e5703c36

+ 14 - 12
dist/replica/_plan9.db

@@ -116,6 +116,7 @@
 386/bin/aux/mnihongo - 775 sys sys 1104121979 138518
 386/bin/aux/mouse - 775 sys sys 1104121979 44026
 386/bin/aux/ms2 - 775 sys sys 1104121980 81824
+386/bin/aux/msexceltables - 775 sys sys 1105019969 80904
 386/bin/aux/mswordstrings - 775 sys sys 1104121980 65317
 386/bin/aux/na - 775 sys sys 1104121980 154635
 386/bin/aux/nfsmount - 775 sys sys 1104121981 234092
@@ -166,7 +167,7 @@
 386/bin/bunzip2 - 775 sys sys 1104121992 97499
 386/bin/bzip2 - 775 sys sys 1104121992 114034
 386/bin/cal - 775 sys sys 1104121993 67886
-386/bin/calendar - 775 sys sys 1104121993 79335
+386/bin/calendar - 775 sys sys 1104984451 79974
 386/bin/cat - 775 sys sys 1104121993 37447
 386/bin/cb - 775 sys sys 1104121993 77519
 386/bin/cdfs - 775 sys sys 1104121994 161088
@@ -227,7 +228,7 @@
 386/bin/fossil/conf - 775 sys sys 1085077052 1506
 386/bin/fossil/flchk - 775 sys sys 1104122009 237497
 386/bin/fossil/flfmt - 775 sys sys 1104122010 245646
-386/bin/fossil/fossil - 775 sys sys 1104898009 360361
+386/bin/fossil/fossil - 775 sys sys 1104984451 360391
 386/bin/fossil/last - 775 sys sys 1104122011 63298
 386/bin/freq - 775 sys sys 1104122011 61802
 386/bin/fs - 20000000775 sys sys 954380769 0
@@ -3033,7 +3034,7 @@ rc/bin/nroff - 775 sys sys 945617208 27
 rc/bin/patch - 20000000775 sys sys 1067803227 0
 rc/bin/patch/applied - 775 sys sys 1081204295 110
 rc/bin/patch/apply - 775 sys sys 1089299188 1276
-rc/bin/patch/create - 775 sys sys 1079969485 1126
+rc/bin/patch/create - 775 sys sys 1104988374 1160
 rc/bin/patch/diff - 775 sys sys 1067804404 466
 rc/bin/patch/list - 775 sys sys 1081204287 644
 rc/bin/patch/move - 775 sys sys 1104430337 565
@@ -3129,6 +3130,7 @@ rc/bin/whois - 775 sys sys 945617210 189
 rc/bin/window - 775 sys sys 1071573331 1781
 rc/bin/wloc - 775 sys sys 969512017 191
 rc/bin/wurl2txt - 755 sys sys 1017431148 296
+rc/bin/xls2txt - 755 sys sys 1105020030 520
 rc/bin/yesterday - 775 sys sys 1084332530 2545
 rc/lib - 20000000775 sys sys 948037639 0
 rc/lib/rcmain - 664 sys sys 984696976 579
@@ -4633,6 +4635,7 @@ sys/log/portmapper - 10000000666 sys sys 958934039 0
 sys/log/ppp - 10000000666 sys sys 958934039 0
 sys/log/pptpd - 10000000666 sys sys 958934039 0
 sys/log/runq - 10000000666 sys sys 1080134438 182
+sys/log/secstore - 10000000666 sys sys 1104988287 0
 sys/log/smtp - 10000000666 sys sys 1080134438 69
 sys/log/smtp.fail - 10000000666 sys sys 958934039 0
 sys/log/smtpd - 10000000666 sys sys 958934040 0
@@ -4681,7 +4684,7 @@ sys/man/1/dc - 664 sys sys 944959674 4834
 sys/man/1/dd - 664 sys sys 1055693436 3346
 sys/man/1/deroff - 664 sys sys 1017423524 1826
 sys/man/1/diff - 664 sys sys 969499884 2793
-sys/man/1/doc2txt - 664 sys sys 954089516 1095
+sys/man/1/doc2txt - 664 sys sys 1105020018 2077
 sys/man/1/doctype - 664 sys sys 944959673 849
 sys/man/1/du - 664 sys sys 1017166323 1410
 sys/man/1/echo - 664 sys sys 1079969656 430
@@ -5126,7 +5129,7 @@ sys/man/8/replica - 664 sys sys 1102088374 6295
 sys/man/8/rsa - 664 sys sys 1057955511 4628
 sys/man/8/scanmail - 664 sys sys 969499895 10803
 sys/man/8/scuzz - 664 sys sys 984709640 7916
-sys/man/8/secstore - 664 sys sys 1064807283 1306
+sys/man/8/secstore - 664 sys sys 1105016705 1954
 sys/man/8/securenet - 664 sys sys 954305552 3160
 sys/man/8/send - 664 sys sys 1045501634 2168
 sys/man/8/smtp - 664 sys sys 1091126310 4724
@@ -5196,7 +5199,7 @@ sys/src/9/alphapc/sd53c8xx.c - 664 sys sys 1015012787 51009
 sys/src/9/alphapc/sdata.c - 664 sys sys 1015012787 25
 sys/src/9/alphapc/sdscsi.c - 664 sys sys 1015012787 26
 sys/src/9/alphapc/sio.c - 664 sys sys 1015012787 293
-sys/src/9/alphapc/trap.c - 664 sys sys 1084475126 18035
+sys/src/9/alphapc/trap.c - 664 sys sys 1105030177 18099
 sys/src/9/alphapc/uarti8250.c - 664 sys sys 1015012788 29
 sys/src/9/alphapc/vga.c - 664 sys sys 1015012788 23
 sys/src/9/alphapc/vgargb524.c - 664 sys sys 1015012788 29
@@ -5251,7 +5254,7 @@ sys/src/9/bitsy/screen.h - 664 sys sys 1017695520 260
 sys/src/9/bitsy/sd.h - 664 sys sys 1037029038 0
 sys/src/9/bitsy/sdata.c - 664 sys sys 1055700868 44660
 sys/src/9/bitsy/tar.c - 664 sys sys 1017695521 1375
-sys/src/9/bitsy/trap.c - 664 sys sys 1084475126 19338
+sys/src/9/bitsy/trap.c - 664 sys sys 1105030166 19484
 sys/src/9/bitsy/uartsa1110.c - 664 sys sys 1037029045 8530
 sys/src/9/bitsy/wavelan.c - 664 sys sys 1064584681 27267
 sys/src/9/bitsy/wavelan.h - 664 sys sys 1037029076 27
@@ -5333,7 +5336,7 @@ sys/src/9/mtx/mtxcpu - 664 sys sys 1039753442 421
 sys/src/9/mtx/pci.c - 664 sys sys 1087657434 16662
 sys/src/9/mtx/random.c - 664 sys sys 1036813598 1983
 sys/src/9/mtx/raven.c - 664 sys sys 1018721288 2587
-sys/src/9/mtx/trap.c - 664 sys sys 1084475126 15856
+sys/src/9/mtx/trap.c - 664 sys sys 1105030157 15882
 sys/src/9/mtx/uarti8250.c - 664 sys sys 1018721288 11590
 sys/src/9/pc - 20000000775 sys sys 1018721225 0
 sys/src/9/pc/apbootstrap.h - 664 sys sys 1018553448 928
@@ -5430,7 +5433,7 @@ sys/src/9/pc/sd53c8xx.n - 664 sys sys 1032059019 12455
 sys/src/9/pc/sdata.c - 664 sys sys 1099487462 50970
 sys/src/9/pc/sdmylex.c - 664 sys sys 1071245460 27812
 sys/src/9/pc/sdscsi.c - 664 sys sys 1077033661 7487
-sys/src/9/pc/trap.c - 664 sys sys 1092080705 20458
+sys/src/9/pc/trap.c - 664 sys sys 1105030146 20520
 sys/src/9/pc/uarti8250.c - 664 sys sys 1102820421 13958
 sys/src/9/pc/uartpci.c - 664 sys sys 1096379063 2891
 sys/src/9/pc/usb.h - 664 sys sys 1099760881 3650
@@ -5579,7 +5582,7 @@ sys/src/9/ppc/msaturn.h - 664 sys sys 1059490753 99
 sys/src/9/ppc/mtx.c - 664 sys sys 1059490753 177
 sys/src/9/ppc/random.c - 664 sys sys 1059490753 1983
 sys/src/9/ppc/saturntimer.c - 664 sys sys 1072705482 1737
-sys/src/9/ppc/trap.c - 664 sys sys 1100701675 18357
+sys/src/9/ppc/trap.c - 664 sys sys 1105030152 18384
 sys/src/9/ppc/uartsaturn.c - 664 sys sys 1059490754 7151
 sys/src/9/ppc/uartsmc.c - 664 sys sys 1068135489 11462
 sys/src/9/ppc/ucu - 664 sys sys 1067722849 672
@@ -12449,5 +12452,4 @@ usr/glenda/lib/profile - 664 glenda glenda 1021580005 847
 usr/glenda/readme.acme - 664 glenda glenda 1019860628 4753
 usr/glenda/readme.rio - 664 glenda glenda 1019860628 6370
 usr/glenda/tmp - 20000000775 glenda glenda 1018802620 0
-386/bin/calendar - 775 sys sys 1104984451 79974
-386/bin/fossil/fossil - 775 sys sys 1104984451 360391
+386/bin/aux/msexceltables - 775 sys sys 1105070896 80904

+ 11 - 8
dist/replica/plan9.db

@@ -116,6 +116,7 @@
 386/bin/aux/mnihongo - 775 sys sys 1104121979 138518
 386/bin/aux/mouse - 775 sys sys 1104121979 44026
 386/bin/aux/ms2 - 775 sys sys 1104121980 81824
+386/bin/aux/msexceltables - 775 sys sys 1105070896 80904
 386/bin/aux/mswordstrings - 775 sys sys 1104121980 65317
 386/bin/aux/na - 775 sys sys 1104121980 154635
 386/bin/aux/nfsmount - 775 sys sys 1104121981 234092
@@ -3033,7 +3034,7 @@ rc/bin/nroff - 775 sys sys 945617208 27
 rc/bin/patch - 20000000775 sys sys 1067803227 0
 rc/bin/patch/applied - 775 sys sys 1081204295 110
 rc/bin/patch/apply - 775 sys sys 1089299188 1276
-rc/bin/patch/create - 775 sys sys 1079969485 1126
+rc/bin/patch/create - 775 sys sys 1104988374 1160
 rc/bin/patch/diff - 775 sys sys 1067804404 466
 rc/bin/patch/list - 775 sys sys 1081204287 644
 rc/bin/patch/move - 775 sys sys 1104430337 565
@@ -3129,6 +3130,7 @@ rc/bin/whois - 775 sys sys 945617210 189
 rc/bin/window - 775 sys sys 1071573331 1781
 rc/bin/wloc - 775 sys sys 969512017 191
 rc/bin/wurl2txt - 755 sys sys 1017431148 296
+rc/bin/xls2txt - 755 sys sys 1105020030 520
 rc/bin/yesterday - 775 sys sys 1084332530 2545
 rc/lib - 20000000775 sys sys 948037639 0
 rc/lib/rcmain - 664 sys sys 984696976 579
@@ -4633,6 +4635,7 @@ sys/log/portmapper - 10000000666 sys sys 958934039 0
 sys/log/ppp - 10000000666 sys sys 958934039 0
 sys/log/pptpd - 10000000666 sys sys 958934039 0
 sys/log/runq - 10000000666 sys sys 1080134438 182
+sys/log/secstore - 10000000666 sys sys 1104988287 0
 sys/log/smtp - 10000000666 sys sys 1080134438 69
 sys/log/smtp.fail - 10000000666 sys sys 958934039 0
 sys/log/smtpd - 10000000666 sys sys 958934040 0
@@ -4681,7 +4684,7 @@ sys/man/1/dc - 664 sys sys 944959674 4834
 sys/man/1/dd - 664 sys sys 1055693436 3346
 sys/man/1/deroff - 664 sys sys 1017423524 1826
 sys/man/1/diff - 664 sys sys 969499884 2793
-sys/man/1/doc2txt - 664 sys sys 954089516 1095
+sys/man/1/doc2txt - 664 sys sys 1105020018 2077
 sys/man/1/doctype - 664 sys sys 944959673 849
 sys/man/1/du - 664 sys sys 1017166323 1410
 sys/man/1/echo - 664 sys sys 1079969656 430
@@ -5126,7 +5129,7 @@ sys/man/8/replica - 664 sys sys 1102088374 6295
 sys/man/8/rsa - 664 sys sys 1057955511 4628
 sys/man/8/scanmail - 664 sys sys 969499895 10803
 sys/man/8/scuzz - 664 sys sys 984709640 7916
-sys/man/8/secstore - 664 sys sys 1064807283 1306
+sys/man/8/secstore - 664 sys sys 1105016705 1954
 sys/man/8/securenet - 664 sys sys 954305552 3160
 sys/man/8/send - 664 sys sys 1045501634 2168
 sys/man/8/smtp - 664 sys sys 1091126310 4724
@@ -5196,7 +5199,7 @@ sys/src/9/alphapc/sd53c8xx.c - 664 sys sys 1015012787 51009
 sys/src/9/alphapc/sdata.c - 664 sys sys 1015012787 25
 sys/src/9/alphapc/sdscsi.c - 664 sys sys 1015012787 26
 sys/src/9/alphapc/sio.c - 664 sys sys 1015012787 293
-sys/src/9/alphapc/trap.c - 664 sys sys 1084475126 18035
+sys/src/9/alphapc/trap.c - 664 sys sys 1105030177 18099
 sys/src/9/alphapc/uarti8250.c - 664 sys sys 1015012788 29
 sys/src/9/alphapc/vga.c - 664 sys sys 1015012788 23
 sys/src/9/alphapc/vgargb524.c - 664 sys sys 1015012788 29
@@ -5251,7 +5254,7 @@ sys/src/9/bitsy/screen.h - 664 sys sys 1017695520 260
 sys/src/9/bitsy/sd.h - 664 sys sys 1037029038 0
 sys/src/9/bitsy/sdata.c - 664 sys sys 1055700868 44660
 sys/src/9/bitsy/tar.c - 664 sys sys 1017695521 1375
-sys/src/9/bitsy/trap.c - 664 sys sys 1084475126 19338
+sys/src/9/bitsy/trap.c - 664 sys sys 1105030166 19484
 sys/src/9/bitsy/uartsa1110.c - 664 sys sys 1037029045 8530
 sys/src/9/bitsy/wavelan.c - 664 sys sys 1064584681 27267
 sys/src/9/bitsy/wavelan.h - 664 sys sys 1037029076 27
@@ -5333,7 +5336,7 @@ sys/src/9/mtx/mtxcpu - 664 sys sys 1039753442 421
 sys/src/9/mtx/pci.c - 664 sys sys 1087657434 16662
 sys/src/9/mtx/random.c - 664 sys sys 1036813598 1983
 sys/src/9/mtx/raven.c - 664 sys sys 1018721288 2587
-sys/src/9/mtx/trap.c - 664 sys sys 1084475126 15856
+sys/src/9/mtx/trap.c - 664 sys sys 1105030157 15882
 sys/src/9/mtx/uarti8250.c - 664 sys sys 1018721288 11590
 sys/src/9/pc - 20000000775 sys sys 1018721225 0
 sys/src/9/pc/apbootstrap.h - 664 sys sys 1018553448 928
@@ -5430,7 +5433,7 @@ sys/src/9/pc/sd53c8xx.n - 664 sys sys 1032059019 12455
 sys/src/9/pc/sdata.c - 664 sys sys 1099487462 50970
 sys/src/9/pc/sdmylex.c - 664 sys sys 1071245460 27812
 sys/src/9/pc/sdscsi.c - 664 sys sys 1077033661 7487
-sys/src/9/pc/trap.c - 664 sys sys 1092080705 20458
+sys/src/9/pc/trap.c - 664 sys sys 1105030146 20520
 sys/src/9/pc/uarti8250.c - 664 sys sys 1102820421 13958
 sys/src/9/pc/uartpci.c - 664 sys sys 1096379063 2891
 sys/src/9/pc/usb.h - 664 sys sys 1099760881 3650
@@ -5579,7 +5582,7 @@ sys/src/9/ppc/msaturn.h - 664 sys sys 1059490753 99
 sys/src/9/ppc/mtx.c - 664 sys sys 1059490753 177
 sys/src/9/ppc/random.c - 664 sys sys 1059490753 1983
 sys/src/9/ppc/saturntimer.c - 664 sys sys 1072705482 1737
-sys/src/9/ppc/trap.c - 664 sys sys 1100701675 18357
+sys/src/9/ppc/trap.c - 664 sys sys 1105030152 18384
 sys/src/9/ppc/uartsaturn.c - 664 sys sys 1059490754 7151
 sys/src/9/ppc/uartsmc.c - 664 sys sys 1068135489 11462
 sys/src/9/ppc/ucu - 664 sys sys 1067722849 672

+ 13 - 0
dist/replica/plan9.log

@@ -18280,3 +18280,16 @@
 1104940940 5 c sys/src/cmd/fossil/fossil-acid - 664 sys sys 1104940044 3991
 1104985950 0 c 386/bin/calendar - 775 sys sys 1104984451 79974
 1104985950 1 c 386/bin/fossil/fossil - 775 sys sys 1104984451 360391
+1104989550 0 c rc/bin/patch/create - 775 sys sys 1104988374 1160
+1104989550 1 a sys/log/secstore - 10000000666 sys sys 1104988287 0
+1104989550 2 c sys/man/8/secstore - 664 sys sys 1104988387 1391
+1105018356 0 c sys/man/8/secstore - 664 sys sys 1105016705 1954
+1105020157 0 a 386/bin/aux/msexceltables - 775 sys sys 1105019969 80904
+1105020157 1 a rc/bin/xls2txt - 755 sys sys 1105020030 520
+1105020157 2 c sys/man/1/doc2txt - 664 sys sys 1105020018 2077
+1105030959 0 c sys/src/9/alphapc/trap.c - 664 sys sys 1105030177 18099
+1105030959 1 c sys/src/9/bitsy/trap.c - 664 sys sys 1105030166 19484
+1105030959 2 c sys/src/9/mtx/trap.c - 664 sys sys 1105030157 15882
+1105030959 3 c sys/src/9/pc/trap.c - 664 sys sys 1105030146 20520
+1105030959 4 c sys/src/9/ppc/trap.c - 664 sys sys 1105030152 18384
+1105072367 0 c 386/bin/aux/msexceltables - 775 sys sys 1105070896 80904

+ 2 - 0
rc/bin/patch/create

@@ -49,6 +49,8 @@ for(i in $*){
 	if not
 		echo warning: new file $i not on sources >[1=2]
 	echo $i $uniq >>$d/files
+	chmod ug+rw $d/*
+	chmod a+r $d/*
 }
 
 if(~ `{cat /proc/$pid/fd | awk 'NR==2{print $NF}'} */dev/cons){

+ 32 - 0
rc/bin/xls2txt

@@ -0,0 +1,32 @@
+#!/bin/rc
+
+rfork en
+
+if(! ~ $#* 0 1) {
+	echo 'usage: xls2txt [file.xls]' >[1=2]
+	exit usage
+}
+
+switch($#*){
+case 0
+	cat >/tmp/xls2txt.$pid
+	file=/tmp/xls2txt.$pid
+case 1
+	file=$1
+}
+aux/olefs $file || { 
+	echo 'xls2txt: couldn''t mount excel document' >[1=2]
+	rm -f /tmp/xls2txt.$pid
+	exit word
+}
+
+if(! test -f /mnt/doc/Workbook) {
+	echo 'xls2txt: is an MSoffice doc but not an Excel document' >[1=2]
+	rm -f /tmp/xls2txt.$pid
+	exit wordxls
+}
+
+aux/msexceltables /mnt/doc/Workbook
+unmount /mnt/doc
+rm -f /tmp/xls2txt.$pid
+

+ 0 - 0
sys/log/secstore


+ 51 - 6
sys/man/1/doc2txt

@@ -1,12 +1,17 @@
 .TH DOC2TXT 1
 .SH NAME
-doc2txt, olefs, mswordstrings \- extract printable strings from Microsoft Word documents
+doc2txt, xls2txt olefs, mswordstrings msexceltable \- extract printable strings from Microsoft Office documents
 .SH SYNOPSIS
 .B doc2txt
 [
 .I file.doc
 ]
 .br
+.B xls2txt
+[
+.I file.xls
+]
+.br
 .B aux/olefs
 [
 .B -m
@@ -16,6 +21,18 @@ doc2txt, olefs, mswordstrings \- extract printable strings from Microsoft Word d
 .br
 .B aux/mswordstrings 
 .I /mnt/doc/WordDocument
+.br
+.B aux/msexceltable
+[
+.B -n
+] [
+.B -t
+] [
+.B -a
+] [
+.BI -d delim
+]
+.I /mnt/doc/Workbook
 .SH DESCRIPTION
 .I Doc2txt
 is a shell script that uses 
@@ -23,6 +40,8 @@ is a shell script that uses
 and
 .I mswordstrings
 to extract the printable text from the body of a Microsoft Word document.
+.I Xls2txt
+performs a similar function for Microsoft Excel documents.
 .PP
 Microsoft Office documents are stored in OLE (Object Linking and Embedding)
 format, which is a scaled down version of Microsoft's FAT file system.
@@ -33,16 +52,39 @@ on
 which defaults to
 .BR /mnt/doc .
 .I Mswordstrings
-parses the 
-.I WordDocument
-file inside an Office document, extracting
-the text stream.
+or
+.I msexceltables
+may then be used to parse the files inside, extracting
+a text stream.
+.I Msexceltables
+may be given options to control the formatting of its output.
+.TP
+-n
+Disables field padding to colum width.
+.TP
+-t
+Truncate fields to the colum width.
+.TP
+-a
+Attempt conversion of non-tabular sheets in the workbook. (charts).
+.TP
+-d \fIdelim\fR
+Sets the interfield delimiter to the string \fIdelim\fR, by default a single space.
 .SH SOURCE
 .B /sys/src/cmd/aux/mswordstrings.c
 .br
+.B /sys/src/cmd/aux/msexceltables.c
+.br
 .B /sys/src/cmd/aux/olefs.c
 .br
+.B /rc/bin/xls2txt
+.br
 .B /rc/bin/doc2txt
+.SH BUGS
+.I Msexcelstrings
+cannot parse files containing rich text field descriptions or Asian phonetic
+pronunciation hints due to a lack of ducumentation on these formats; It has
+only been tested on BIFF8 files generated by MS Office 97; Caveat Emptor.
 .SH SEE ALSO
 .IR strings (1)
 .br
@@ -50,4 +92,7 @@ the text stream.
 available on line at Microsoft's developer home page.
 .br
 ``LAOLA Binary Structures'', 
-.IR snake.cs.tu-berlin.de:8081/~schwartz/pmh .
+.I http://snake.cs.tu-berlin.de:8081/~schwartz/pmh 
+.br
+``OpenOffice.Org's Excel Documentation'',
+.I http:\/\/sc.openoffice.org/excelfileformat.pdf

+ 65 - 22
sys/man/8/secstore

@@ -4,30 +4,57 @@ secstored, secuser \- secstore commands
 .SH SYNOPSIS
 .br
 .B auth/secstored
-[-R]
-[-S servername]
-[-s tcp!*!5356]
-[-x mountpoint]
-.br
-.B auth/secuser
-[-v]
-username
-.br
+.RB [ -R ]
+[
+.BI -S " servername"
+] [
+.BI -s " address"
+] [
+.BI -x " network"
+] [
+.B -v
+]
 .PP
+.B auth/secuser
+[
+.B -v
+]
+.I username
 .SH DESCRIPTION
-.PP
 .I Secstored
 serves requests from
 .IR secstore (1).
+By default it listens on port
+.BR tcp!*!5356 ;
+the
+.B -s
+option specifies an alternative
+.IR address .
+In the connection protocol,
+.I secstored
+describes itself as service
+.BR secstore ,
+but the
+.B -S
+option can specify a different
+.IR servername .
 The
 .B -R
 option supplements the password check with a
 call to a RADIUS server, for checking hardware
 tokens or other validation.
 The
-.BR -x mountpoint
-option specifies an alternative to the default network
+.B -x
+option specifies an alternative
+.I network
+to the default
 .BR /net .
+By default,
+.I secstored
+puts itself into the background;
+the
+.B -v
+option enables a verbose debugging mode that suppresses that.
 .PP
 .I Secuser
 is an administrative command that runs on the
@@ -36,11 +63,17 @@ to create new accounts and
 to change status on existing accounts.
 It prompts for account information such as
 password and expiration date, writing to
-.BR /adm/secstore/who/$uid .
-The
+.BI /adm/secstore/who/ user
+for a given secstore
+.IR user .
+The directory
 .B /adm/secstore
-directory should be created mode 770 for the userid
-or groupid of the secstored process.
+should be created mode 770 with owner or group allowing access to the user
+that runs
+.IR secstored .
+The
+.B -v
+option makes the command chattier.
 .PP
 By default,
 .I secstored
@@ -50,14 +83,24 @@ If you prefer to obscure this information, use
 to create an account
 .BR FICTITIOUS .
 .SH FILES
-.B /adm/secstore/who/$uid
-secstore account name, expiration date, verifier
-.br
-.B /adm/secstore/store/$uid/
-users' files
-.br
+.TF /adm/secstore/store/user/
+.TP
+.BI /adm/secstore/who/ user
+.I secstore
+account name, expiration date, verifier
+.TP
+.BI /adm/secstore/store/ user /
+.I user 's
+file storage
+.TP
 .B /lib/ndb/auth
 for mapping local userid to RADIUS userid
+.TP
+.B /sys/log/secstore
+log file (if it does not exist,
+.I secstored
+logs to
+.BR /dev/cons )
 .SH SOURCE
 .B /sys/src/cmd/auth/secstore
 .SH SEE ALSO

+ 5 - 3
sys/src/9/alphapc/trap.c

@@ -247,7 +247,7 @@ intr(Ureg *ur)
 		if(ctl->eoi)
 			ctl->eoi(vno);
 
-		if(ctl->isintr)
+		if(ctl->isintr && up)
 			preempted();
 	}
 	else if(vno >= VectorPIC && vno <= MaxVectorPIC){
@@ -283,7 +283,7 @@ void
 trap(Ureg *ur)
 {
 	char buf[ERRMAX];
-	int user, x;
+	int clockintr, user, x;
 
 	user = ur->status&UMODE;
 
@@ -291,6 +291,7 @@ trap(Ureg *ur)
 		up = m->proc;
 		up->dbgreg = ur;
 	}
+	clockintr = 0;
 	switch ((int)ur->type) {
 	case 1:	/* arith */
 		fptrap(ur);
@@ -306,6 +307,7 @@ trap(Ureg *ur)
 			panic("interprocessor intr");
 			break;
 		case 1:	/* clock */
+			clockintr = 1;
 			clock(ur);
 			break;
 		case 2:	/* machine check */
@@ -346,7 +348,7 @@ trap(Ureg *ur)
 	splhi();
 
 	/* delaysched set because we held a lock or because our quantum ended */
-	if(up && up->delaysched){
+	if(up && up->delaysched && clockintr){
 		sched();
 		splhi();
 	}

+ 13 - 6
sys/src/9/bitsy/trap.c

@@ -31,7 +31,7 @@ typedef struct Vpage0 {
 } Vpage0;
 Vpage0 *vpage0;
 
-static void	irq(Ureg*);
+static int	irq(Ureg*);
 static void	gpiointr(Ureg*, void*);
 
 /* recover state after power suspend
@@ -337,7 +337,7 @@ void
 trap(Ureg *ureg)
 {
 	ulong inst;
-	int user, x, rv;
+	int clockintr, user, x, rv;
 	ulong va, fsr;
 	char buf[ERRMAX];
 	int rem;
@@ -363,12 +363,13 @@ trap(Ureg *ureg)
 	else
 		ureg->pc -= 4;
 
+	clockintr = 0;
 	switch(ureg->type){
 	default:
 		panic("unknown trap");
 		break;
 	case PsrMirq:
-		irq(ureg);
+		clockintr = irq(ureg);
 		break;
 	case PsrMabt:	/* prefetch fault */
 		faultarm(ureg, ureg->pc, user, 1);
@@ -443,7 +444,7 @@ trap(Ureg *ureg)
 	splhi();
 
 	/* delaysched set because we held a lock or because our quantum ended */
-	if(up && up->delaysched){
+	if(up && up->delaysched && clockintr){
 		sched();
 		splhi();
 	}
@@ -458,15 +459,19 @@ trap(Ureg *ureg)
 /*
  *  here on irq's
  */
-static void
+static int
 irq(Ureg *ur)
 {
 	ulong va;
-	int i;
+	int clockintr, i;
 	Vctl *v;
 
 	va = intrregs->icip;
 
+	if(va & (1<<IRQtimer0))
+		clockintr = 1;
+	else
+		clockintr = 0;
 	for(i = 0; i < 32; i++){
 		if(((1<<i) & va) == 0)
 			continue;
@@ -477,6 +482,8 @@ irq(Ureg *ur)
 	}
 	if(va)
 		print("unknown interrupt: %lux\n", va);
+
+	return clockintr;
 }
 
 /*

+ 3 - 2
sys/src/9/mtx/trap.c

@@ -299,7 +299,7 @@ trap(Ureg *ureg)
 	splhi();
 
 	/* delaysched set because we held a lock or because our quantum ended */
-	if(up && up->delaysched){
+	if(up && up->delaysched && ecode == CDEC){
 		sched();
 		splhi();
 	}
@@ -395,7 +395,8 @@ intr(Ureg *ureg)
 	if(ctl->eoi)
 		ctl->eoi(vno);
 
-	preempted();
+	if(up)
+		preempted();
 }
 
 char*

+ 6 - 3
sys/src/9/pc/trap.c

@@ -301,7 +301,7 @@ kexit(Ureg*)
 void
 trap(Ureg* ureg)
 {
-	int i, vno, user;
+	int clockintr, i, vno, user;
 	char buf[ERRMAX];
 	Vctl *ctl, *v;
 	Mach *mach;
@@ -333,7 +333,10 @@ trap(Ureg* ureg)
 		if(ctl->isintr){
 			intrtime(m, vno);
 
-			if(up && ctl->irq != IrqTIMER && ctl->irq != IrqCLOCK)
+			if(ctl->irq == IrqCLOCK || ctl->irq == IrqTIMER)
+				clockintr = 1;
+
+			if(up && !clockintr)
 				preempted();
 		}
 	}
@@ -411,7 +414,7 @@ trap(Ureg* ureg)
 	splhi();
 
 	/* delaysched set because we held a lock or because our quantum ended */
-	if(up && up->delaysched){
+	if(up && up->delaysched && clockintr){
 		sched();
 		splhi();
 	}

+ 4 - 2
sys/src/9/ppc/trap.c

@@ -291,7 +291,7 @@ trap(Ureg *ureg)
 	splhi();
 
 	/* delaysched set because we held a lock or because our quantum ended */
-	if(up && up->delaysched){
+	if(up && up->delaysched && ecode == CDEC){
 		sched();
 		splhi();
 	}
@@ -463,7 +463,9 @@ intr(Ureg *ureg)
 		thisto[i]++;
 	else
 		thistoo++;
-	preempted();
+
+	if(up)
+		preempted();
 }
 
 char*