Browse Source

Plan 9 from Bell Labs 2005-08-25

David du Colombier 15 years ago
parent
commit
d35acbecef

+ 45 - 20
dist/replica/_plan9.db

@@ -1,15 +1,15 @@
 386 - 20000000775 sys sys 1010957353 0
 386/9load - 775 sys sys 1112757508 215872
-386/9loaddebug - 775 sys sys 1121398844 310435
+386/9loaddebug - 775 sys sys 1124856571 310547
 386/9loadlite - 775 sys sys 1112757508 135244
 386/9loadlitedebug - 775 sys sys 1121398844 198794
-386/9pc - 775 sys sys 1123301357 1835193
+386/9pc - 775 sys sys 1124856576 1836888
 386/9pc.gz - 664 sys sys 1112757510 643423
-386/9pccpu - 775 sys sys 1123301360 1489449
+386/9pccpu - 775 sys sys 1124856579 1491144
 386/9pccpu.gz - 664 sys sys 1112757511 529529
-386/9pcdisk - 775 sys sys 1123301364 2040991
+386/9pcdisk - 775 sys sys 1124856583 2042686
 386/9pcdisk.gz - 664 sys sys 1112757513 733576
-386/9pcf - 775 sys sys 1123301369 2383815
+386/9pcf - 775 sys sys 1124856588 2385510
 386/9pcf.gz - 664 sys sys 1112757515 886966
 386/9pxeload - 775 sys sys 1112757508 215872
 386/_9pcdisk.gz - 664 sys sys 1039764191 695837
@@ -438,7 +438,7 @@
 386/bin/units - 775 sys sys 1115950124 75250
 386/bin/unlnfs - 775 sys sys 1115950124 71362
 386/bin/unmount - 775 sys sys 1115950124 36611
-386/bin/unzip - 775 sys sys 1115950125 89733
+386/bin/unzip - 775 sys sys 1124856570 89971
 386/bin/upas - 20000000775 sys sys 1016857390 0
 386/bin/upas/addhash - 775 sys sys 1064598343 67859
 386/bin/upas/aliasmail - 775 sys sys 1116990554 105039
@@ -2969,7 +2969,7 @@ lib/font/bit/lucidasans/typeunicode.9.font - 464 sys sys 1115917409 1678
 lib/font/bit/lucidasans/unicode.10.font - 664 sys sys 1115914025 2042
 lib/font/bit/lucidasans/unicode.13.font - 664 sys sys 1116086405 1898
 lib/font/bit/lucidasans/unicode.6.font - 664 sys sys 1115914026 1945
-lib/font/bit/lucidasans/unicode.7.font - 664 sys sys 1115914026 1988
+lib/font/bit/lucidasans/unicode.7.font - 664 sys sys 1124884861 2042
 lib/font/bit/lucidasans/unicode.8.font - 664 sys sys 1115917409 2095
 lib/font/bit/lucidasans/unicode.8.font1 - 664 sys sys 944943795 476
 lib/font/bit/lucidasans/unicode.9x24.font - 664 sys sys 944943794 1922
@@ -5250,6 +5250,7 @@ mail/lib/smtpd.conf.ext - 664 upas upas 1089299188 1032
 mail/lib/spam.rc - 775 upas upas 1063950954 400
 mail/lib/unspam.rc - 775 upas upas 1063950954 400
 mail/lib/validateaddress - 775 upas upas 1098803974 48
+mail/lib/validateattachment - 775 upas upas 1124885063 680
 mail/lib/validatesender - 775 upas upas 1106233741 1128
 mail/lib/white.starter - 664 upas upas 1067739606 326
 mail/queue - 20000000777 upas upas 953302652 0
@@ -5763,7 +5764,7 @@ sys/games - 20000000775 sys sys 952648872 0
 sys/games/lib - 20000000775 sys sys 952648879 0
 sys/games/lib/4scores - 10000000664 sys sys 1118680448 0
 sys/games/lib/5scores - 10000000664 sys sys 1118680453 0
-sys/games/lib/fortunes - 664 sys sys 1124716792 255238
+sys/games/lib/fortunes - 664 sys sys 1124931511 255388
 sys/games/lib/mahjongg - 20000000775 sys sys 1095792278 0
 sys/games/lib/mahjongg/backgrounds - 20000000775 sys sys 1095792293 0
 sys/games/lib/mahjongg/backgrounds/default.bit - 664 sys sys 1095792293 346803
@@ -7276,7 +7277,7 @@ sys/man/1/expect - 664 sys sys 1058791094 3023
 sys/man/1/faces - 664 sys sys 1113743326 2395
 sys/man/1/factor - 664 sys sys 957920005 1019
 sys/man/1/file - 664 sys sys 1015024739 1578
-sys/man/1/filter - 664 sys sys 1041108741 4403
+sys/man/1/filter - 664 sys sys 1124885098 4619
 sys/man/1/fmt - 664 sys sys 1070032221 1557
 sys/man/1/fortune - 664 sys sys 944959673 449
 sys/man/1/freq - 664 sys sys 944959673 735
@@ -8085,7 +8086,7 @@ sys/src/9/port/mkdevlist - 775 sys sys 1055700519 510
 sys/src/9/port/mkerrstr - 775 sys sys 1015278340 75
 sys/src/9/port/mkextract - 775 sys sys 1039753334 435
 sys/src/9/port/mkfile - 664 sys sys 1063856960 350
-sys/src/9/port/mkfilelist - 775 sys sys 1109202242 203
+sys/src/9/port/mkfilelist - 775 sys sys 1124890427 266
 sys/src/9/port/mkroot - 775 sys sys 1039753334 235
 sys/src/9/port/mkrootall - 775 sys sys 1055954696 386
 sys/src/9/port/mkrootc - 775 sys sys 1055954695 717
@@ -9522,7 +9523,7 @@ sys/src/cmd/aux/flashfs/entry.c - 664 sys sys 1015009081 7936
 sys/src/cmd/aux/flashfs/errors.c - 664 sys sys 1015009081 286
 sys/src/cmd/aux/flashfs/flash.c - 664 sys sys 1015009081 973
 sys/src/cmd/aux/flashfs/flashfs.h - 664 sys sys 1015092280 3422
-sys/src/cmd/aux/flashfs/journal.c - 664 sys sys 1015009081 14297
+sys/src/cmd/aux/flashfs/journal.c - 664 sys sys 1124916236 14317
 sys/src/cmd/aux/flashfs/mkfile - 664 sys sys 1015009082 649
 sys/src/cmd/aux/flashfs/mkfs.c - 664 sys sys 1015009082 1072
 sys/src/cmd/aux/flashfs/mkit - 775 sys sys 1015009082 86
@@ -9548,7 +9549,7 @@ sys/src/cmd/aux/mnihongo/mnihongo.c - 664 sys sys 946759402 6406
 sys/src/cmd/aux/mnihongo/tmac.nihongo - 664 sys sys 944960789 22
 sys/src/cmd/aux/mouse.c - 664 sys sys 1063855425 7049
 sys/src/cmd/aux/ms2.c - 664 sys sys 1124305056 3153
-sys/src/cmd/aux/msexceltables.c - 664 sys sys 1124709007 13935
+sys/src/cmd/aux/msexceltables.c - 664 sys sys 1124933681 13912
 sys/src/cmd/aux/mswordstrings.c - 664 sys sys 952201344 5767
 sys/src/cmd/aux/na - 20000000775 sys sys 955036627 0
 sys/src/cmd/aux/na/mkfile - 664 sys sys 955036627 121
@@ -9584,7 +9585,7 @@ sys/src/cmd/aux/vga/error.c - 664 sys sys 1014925008 745
 sys/src/cmd/aux/vga/et4000.c - 664 sys sys 1014925008 6720
 sys/src/cmd/aux/vga/et4000hwgc.c - 664 sys sys 1014925008 552
 sys/src/cmd/aux/vga/hiqvideo.c - 664 sys sys 1048635653 9211
-sys/src/cmd/aux/vga/i81x.c - 664 sys sys 1062391404 11759
+sys/src/cmd/aux/vga/i81x.c - 664 sys sys 1124916404 11755
 sys/src/cmd/aux/vga/ibm8514.c - 664 sys sys 1014925009 2389
 sys/src/cmd/aux/vga/icd2061a.c - 664 sys sys 1014925009 2152
 sys/src/cmd/aux/vga/ics2494.c - 664 sys sys 1014925009 2000
@@ -11866,7 +11867,7 @@ sys/src/cmd/gzip - 20000000775 sys sys 984789976 0
 sys/src/cmd/gzip/gunzip.c - 664 sys sys 1014924864 6039
 sys/src/cmd/gzip/gzip.c - 664 sys sys 1014924864 3646
 sys/src/cmd/gzip/gzip.h - 664 sys sys 954778718 1058
-sys/src/cmd/gzip/mkfile - 664 sys sys 984758036 125
+sys/src/cmd/gzip/mkfile - 664 sys sys 1124884920 124
 sys/src/cmd/gzip/unzip.c - 664 sys sys 1124839686 13816
 sys/src/cmd/gzip/zip.c - 664 sys sys 1033183074 7054
 sys/src/cmd/gzip/zip.h - 664 sys sys 954778719 1428
@@ -11918,7 +11919,7 @@ sys/src/cmd/ip/ftpfs/file.c - 664 sys sys 1014925642 4208
 sys/src/cmd/ip/ftpfs/ftpfs.c - 664 sys sys 1116737713 13860
 sys/src/cmd/ip/ftpfs/ftpfs.h - 664 sys sys 1091904423 2353
 sys/src/cmd/ip/ftpfs/mkfile - 664 sys sys 1048312050 173
-sys/src/cmd/ip/ftpfs/proto.c - 664 sys sys 1112563713 30346
+sys/src/cmd/ip/ftpfs/proto.c - 664 sys sys 1124935667 30337
 sys/src/cmd/ip/glob.c - 664 sys sys 1101155057 3290
 sys/src/cmd/ip/glob.h - 664 sys sys 1101155058 308
 sys/src/cmd/ip/gping.c - 664 sys sys 1015013112 20476
@@ -11965,7 +11966,7 @@ sys/src/cmd/ip/imap4d/nodes.c - 664 sys sys 1015013077 3173
 sys/src/cmd/ip/imap4d/search.c - 664 sys sys 1015013077 4520
 sys/src/cmd/ip/imap4d/store.c - 664 sys sys 1066317059 1910
 sys/src/cmd/ip/imap4d/utils.c - 664 sys sys 1015013077 2481
-sys/src/cmd/ip/ipconfig.c - 664 sys sys 1084471140 34896
+sys/src/cmd/ip/ipconfig.c - 664 sys sys 1124936750 34907
 sys/src/cmd/ip/measure.c - 664 sys sys 944961011 3733
 sys/src/cmd/ip/mkfile - 664 sys sys 1089739069 1232
 sys/src/cmd/ip/ping.c - 664 sys sys 1084471009 5651
@@ -13411,7 +13412,7 @@ sys/src/cmd/upas/unesc/mkfile - 664 sys sys 1075080255 164
 sys/src/cmd/upas/unesc/unesc.c - 664 sys sys 1075080255 789
 sys/src/cmd/upas/vf - 20000000775 sys sys 1015096796 0
 sys/src/cmd/upas/vf/mkfile - 664 sys sys 1064393881 241
-sys/src/cmd/upas/vf/vf.c - 664 sys sys 1102093227 17450
+sys/src/cmd/upas/vf/vf.c - 664 sys sys 1124885103 20004
 sys/src/cmd/usb - 20000000775 sys sys 1017802022 0
 sys/src/cmd/usb/audio - 20000000775 sys sys 1017802021 0
 sys/src/cmd/usb/audio/audiofs.c - 664 sys sys 1100568596 18166
@@ -13866,7 +13867,7 @@ sys/src/lib9p/post.c - 664 sys sys 1103565871 356
 sys/src/lib9p/post.h - 664 sys sys 1029850260 201
 sys/src/lib9p/ramfs.c - 664 sys sys 1030450927 2534
 sys/src/lib9p/req.c - 664 sys sys 1089299187 1652
-sys/src/lib9p/srv.c - 664 sys sys 1050583820 16705
+sys/src/lib9p/srv.c - 664 sys sys 1124911050 16885
 sys/src/lib9p/tpost.c - 664 sys sys 1103565872 316
 sys/src/lib9p/uid.c - 664 sys sys 1015023311 517
 sys/src/lib9p/util.c - 664 sys sys 1017679319 465
@@ -14800,7 +14801,7 @@ sys/src/libsec/port/sha1pickle.c - 664 sys sys 988225292 717
 sys/src/libsec/port/smallprimes.c - 664 sys sys 984710525 6851
 sys/src/libsec/port/smallprimetest.c - 664 sys sys 984710525 70640
 sys/src/libsec/port/thumb.c - 664 sys sys 1019832052 1891
-sys/src/libsec/port/tlshand.c - 664 sys sys 1124709122 54987
+sys/src/libsec/port/tlshand.c - 664 sys sys 1124935566 54999
 sys/src/libsec/port/x509.c - 664 sys sys 1063853597 50342
 sys/src/libsec/power - 20000000775 sys sys 984710502 0
 sys/src/libsec/power/mkfile - 664 sys sys 1032061453 139
@@ -14958,4 +14959,28 @@ usr/glenda/lib/profile - 664 glenda glenda 1105128663 890
 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/unzip - 775 sys sys 1124853144 89971
+386/bin/archfs - 775 sys sys 1124939596 140892
+386/bin/cdfs - 775 sys sys 1124939600 161202
+386/bin/nntpfs - 775 sys sys 1124939604 161027
+386/bin/snapfs - 775 sys sys 1124939605 372687
+386/bin/webcookies - 775 sys sys 1124939607 161634
+386/bin/wikifs - 775 sys sys 1124939608 201761
+386/bin/rdbfs - 775 sys sys 1124939604 168509
+386/bin/webfs - 775 sys sys 1124939607 349707
+386/bin/auth/factotum - 775 sys sys 1124939596 312512
+386/bin/aux/apm - 775 sys sys 1124939597 174208
+386/bin/aux/disksim - 775 sys sys 1124939597 144461
+386/bin/aux/flashfs - 775 sys sys 1124939598 160399
+386/bin/aux/gpsfs - 775 sys sys 1124939598 176225
+386/bin/aux/msexceltables - 775 sys sys 1124939598 81233
+386/bin/aux/olefs - 775 sys sys 1124939599 143372
+386/bin/aux/stub - 775 sys sys 1124939599 135175
+386/bin/aux/vga - 775 sys sys 1124939600 333559
+386/bin/execnet - 775 sys sys 1124939601 172009
+386/bin/ext2srv - 775 sys sys 1124939601 174007
+386/bin/mntgen - 775 sys sys 1124939602 139306
+386/bin/nfs - 775 sys sys 1124939603 315518
+386/bin/sshnet - 775 sys sys 1124939606 282851
+386/bin/upas/vf - 775 sys sys 1124939606 97002
+386/lib/lib9p.a - 664 sys sys 1124939608 79582
+acme/bin/386/win - 775 sys sys 1124939608 178958

+ 45 - 44
dist/replica/plan9.db

@@ -1,15 +1,15 @@
 386 - 20000000775 sys sys 1010957353 0
 386/9load - 775 sys sys 1112757508 215872
-386/9loaddebug - 775 sys sys 1121398844 310435
+386/9loaddebug - 775 sys sys 1124856571 310547
 386/9loadlite - 775 sys sys 1112757508 135244
 386/9loadlitedebug - 775 sys sys 1121398844 198794
-386/9pc - 775 sys sys 1123301357 1835193
+386/9pc - 775 sys sys 1124856576 1836888
 386/9pc.gz - 664 sys sys 1112757510 643423
-386/9pccpu - 775 sys sys 1123301360 1489449
+386/9pccpu - 775 sys sys 1124856579 1491144
 386/9pccpu.gz - 664 sys sys 1112757511 529529
-386/9pcdisk - 775 sys sys 1123301364 2040991
+386/9pcdisk - 775 sys sys 1124856583 2042686
 386/9pcdisk.gz - 664 sys sys 1112757513 733576
-386/9pcf - 775 sys sys 1123301369 2383815
+386/9pcf - 775 sys sys 1124856588 2385510
 386/9pcf.gz - 664 sys sys 1112757515 886966
 386/9pxeload - 775 sys sys 1112757508 215872
 386/_9pcdisk.gz - 664 sys sys 1039764191 695837
@@ -39,7 +39,7 @@
 386/bin/ape/uname - 775 sys sys 1087442505 132510
 386/bin/aquarela - 775 sys sys 1064598027 319170
 386/bin/ar - 775 sys sys 1115950026 110847
-386/bin/archfs - 775 sys sys 1115950026 140779
+386/bin/archfs - 775 sys sys 1124939596 140892
 386/bin/ascii - 775 sys sys 1115950026 64668
 386/bin/astro - 775 sys sys 1119496641 138819
 386/bin/auth - 20000000775 sys sys 1016920815 0
@@ -53,7 +53,7 @@
 386/bin/auth/debug - 775 sys sys 1115950029 101064
 386/bin/auth/disable - 775 sys sys 1020319057 146
 386/bin/auth/enable - 775 sys sys 1020319057 134
-386/bin/auth/factotum - 775 sys sys 1117249743 312399
+386/bin/auth/factotum - 775 sys sys 1124939596 312512
 386/bin/auth/fgui - 775 sys sys 1115950030 217869
 386/bin/auth/guard.srv - 775 sys sys 1115950030 142850
 386/bin/auth/iam - 775 sys sys 1085076981 50791
@@ -85,7 +85,7 @@
 386/bin/aux/accupoint - 775 sys sys 1115950037 40059
 386/bin/aux/acidleak - 775 sys sys 1119496642 69433
 386/bin/aux/antiword - 775 sys sys 1070288096 511478
-386/bin/aux/apm - 775 sys sys 1115950038 174095
+386/bin/aux/apm - 775 sys sys 1124939597 174208
 386/bin/aux/astarld - 775 sys sys 1115950038 64692
 386/bin/aux/cddb - 775 sys sys 1115950038 71994
 386/bin/aux/clog - 775 sys sys 1115950038 66450
@@ -94,15 +94,15 @@
 386/bin/aux/cropmarks - 775 sys sys 1020319062 1808
 386/bin/aux/data2s - 775 sys sys 1115950039 60537
 386/bin/aux/depend - 775 sys sys 1115950039 145518
-386/bin/aux/disksim - 775 sys sys 1115950040 144348
+386/bin/aux/disksim - 775 sys sys 1124939597 144461
 386/bin/aux/download - 775 sys sys 1087442506 176016
 386/bin/aux/faxreceive - 775 sys sys 1115950040 83936
 386/bin/aux/faxsend - 775 sys sys 1115950040 89448
-386/bin/aux/flashfs - 775 sys sys 1115950040 160286
+386/bin/aux/flashfs - 775 sys sys 1124939598 160399
 386/bin/aux/g3p9bit - 775 sys sys 1104121976 67278
 386/bin/aux/getflags - 775 sys sys 1115950040 43817
 386/bin/aux/gpsevermore - 775 sys sys 1115950041 71417
-386/bin/aux/gpsfs - 775 sys sys 1115950041 176112
+386/bin/aux/gpsfs - 775 sys sys 1124939598 176225
 386/bin/aux/grabit - 775 sys sys 1020319063 1244
 386/bin/aux/hardcopy - 775 sys sys 1020319063 1699
 386/bin/aux/isvmware - 775 sys sys 1032486791 23997
@@ -118,12 +118,12 @@
 386/bin/aux/mnihongo - 775 sys sys 1115950044 139321
 386/bin/aux/mouse - 775 sys sys 1115950044 44026
 386/bin/aux/ms2 - 775 sys sys 1124335228 85677
-386/bin/aux/msexceltables - 775 sys sys 1124766753 81264
+386/bin/aux/msexceltables - 775 sys sys 1124939598 81233
 386/bin/aux/mswordstrings - 775 sys sys 1115950044 65317
 386/bin/aux/na - 775 sys sys 1115950045 154186
 386/bin/aux/nfsmount - 775 sys sys 1115950045 234092
 386/bin/aux/nfsserver - 775 sys sys 1115950046 185411
-386/bin/aux/olefs - 775 sys sys 1115950046 143259
+386/bin/aux/olefs - 775 sys sys 1124939599 143372
 386/bin/aux/p9bitpost - 775 sys sys 1104121982 127974
 386/bin/aux/pcmcia - 775 sys sys 1115950047 46905
 386/bin/aux/pcnfsd - 775 sys sys 1115950047 129339
@@ -140,14 +140,14 @@
 386/bin/aux/sprog - 775 sys sys 1115950049 79349
 386/bin/aux/ssh_genkey - 775 sys sys 1045537957 194629
 386/bin/aux/sshserve - 775 sys sys 1119496643 251497
-386/bin/aux/stub - 775 sys sys 1115950050 135062
+386/bin/aux/stub - 775 sys sys 1124939599 135175
 386/bin/aux/tcpostio - 775 sys sys 1094040084 200808
 386/bin/aux/text2post - 775 sys sys 1104121986 78336
 386/bin/aux/timesync - 775 sys sys 1116126317 128213
 386/bin/aux/tr2post - 775 sys sys 1104121987 176578
 386/bin/aux/trampoline - 775 sys sys 1115950050 83293
 386/bin/aux/typepasswd - 775 sys sys 1115950050 69503
-386/bin/aux/vga - 775 sys sys 1116903728 333567
+386/bin/aux/vga - 775 sys sys 1124939600 333559
 386/bin/aux/vmmousepoll - 775 sys sys 1032480572 41434
 386/bin/aux/vmware - 775 sys sys 1049428256 453
 386/bin/aux/vmwarefs - 775 sys sys 1095563640 99117
@@ -172,7 +172,7 @@
 386/bin/calendar - 775 sys sys 1116903731 80221
 386/bin/cat - 775 sys sys 1115950056 37447
 386/bin/cb - 775 sys sys 1115950056 77519
-386/bin/cdfs - 775 sys sys 1115950056 161088
+386/bin/cdfs - 775 sys sys 1124939600 161202
 386/bin/cfs - 775 sys sys 1115950056 128067
 386/bin/chgrp - 775 sys sys 1115950056 59285
 386/bin/chmod - 775 sys sys 1115950057 62281
@@ -218,9 +218,9 @@
 386/bin/echo - 775 sys sys 1115950066 57355
 386/bin/ed - 775 sys sys 1115950066 93034
 386/bin/eqn - 775 sys sys 1087442511 242933
-386/bin/execnet - 775 sys sys 1115950067 171896
+386/bin/execnet - 775 sys sys 1124939601 172009
 386/bin/exportfs - 775 sys sys 1115950067 161171
-386/bin/ext2srv - 775 sys sys 1115950067 173894
+386/bin/ext2srv - 775 sys sys 1124939601 174007
 386/bin/faces - 775 sys sys 1115950068 193388
 386/bin/factor - 775 sys sys 1115950068 61475
 386/bin/fcp - 775 sys sys 1115950068 82162
@@ -323,7 +323,7 @@
 386/bin/mk - 775 sys sys 1123729447 144048
 386/bin/mkdir - 775 sys sys 1115950093 60964
 386/bin/mkpaqfs - 775 sys sys 1115950093 94509
-386/bin/mntgen - 775 sys sys 1115950094 139193
+386/bin/mntgen - 775 sys sys 1124939602 139306
 386/bin/mount - 775 sys sys 1115950094 73011
 386/bin/ms2html - 775 sys sys 1115950094 103585
 386/bin/mtime - 775 sys sys 1115950094 59139
@@ -343,9 +343,9 @@
 386/bin/netkey - 775 sys sys 1115950098 72307
 386/bin/netstat - 775 sys sys 1116126323 84385
 386/bin/news - 775 sys sys 1119496653 71669
-386/bin/nfs - 775 sys sys 1119496653 315405
+386/bin/nfs - 775 sys sys 1124939603 315518
 386/bin/nm - 775 sys sys 1119496654 121803
-386/bin/nntpfs - 775 sys sys 1119496654 160914
+386/bin/nntpfs - 775 sys sys 1124939604 161027
 386/bin/ns - 775 sys sys 1115950100 65260
 386/bin/p - 775 sys sys 1115950100 64990
 386/bin/page - 775 sys sys 1118671839 232775
@@ -368,7 +368,7 @@
 386/bin/pwd - 775 sys sys 1115950105 36897
 386/bin/ramfs - 775 sys sys 1115950105 89167
 386/bin/rc - 775 sys sys 1119496655 143226
-386/bin/rdbfs - 775 sys sys 1115950106 168396
+386/bin/rdbfs - 775 sys sys 1124939604 168509
 386/bin/read - 775 sys sys 1115950106 58046
 386/bin/replica - 20000000775 sys sys 1018321168 0
 386/bin/replica/applychanges - 775 sys sys 1115950107 98562
@@ -394,7 +394,7 @@
 386/bin/size - 775 sys sys 1119496658 76974
 386/bin/sleep - 775 sys sys 1085077097 3413
 386/bin/snap - 775 sys sys 1119496658 303720
-386/bin/snapfs - 775 sys sys 1119496659 372574
+386/bin/snapfs - 775 sys sys 1124939605 372687
 386/bin/sniffer - 775 sys sys 1038443185 99028
 386/bin/snoopy - 775 sys sys 1116126323 157546
 386/bin/sort - 775 sys sys 1115950113 82285
@@ -404,7 +404,7 @@
 386/bin/srvfs - 775 sys sys 1116903736 40065
 386/bin/srvold9p - 775 sys sys 1115950114 130193
 386/bin/ssh - 775 sys sys 1120014537 211039
-386/bin/sshnet - 775 sys sys 1120014538 282738
+386/bin/sshnet - 775 sys sys 1124939606 282851
 386/bin/stats - 775 sys sys 1115950115 190072
 386/bin/strings - 775 sys sys 1115950116 62124
 386/bin/strip - 775 sys sys 1115950116 61981
@@ -438,7 +438,7 @@
 386/bin/units - 775 sys sys 1115950124 75250
 386/bin/unlnfs - 775 sys sys 1115950124 71362
 386/bin/unmount - 775 sys sys 1115950124 36611
-386/bin/unzip - 775 sys sys 1124853144 89971
+386/bin/unzip - 775 sys sys 1124856570 89971
 386/bin/upas - 20000000775 sys sys 1016857390 0
 386/bin/upas/addhash - 775 sys sys 1064598343 67859
 386/bin/upas/aliasmail - 775 sys sys 1116990554 105039
@@ -468,7 +468,7 @@
 386/bin/upas/token - 775 sys sys 1115950132 77554
 386/bin/upas/unesc - 775 sys sys 1087442540 132079
 386/bin/upas/unspam - 775 sys sys 1064598367 38
-386/bin/upas/vf - 775 sys sys 1115950132 92623
+386/bin/upas/vf - 775 sys sys 1124939606 97002
 386/bin/usb - 20000000775 sys sys 1019538890 0
 386/bin/usb/usbaudio - 775 sys sys 1115950132 185541
 386/bin/usb/usbd - 775 sys sys 1115950133 129846
@@ -500,10 +500,10 @@
 386/bin/vt - 775 sys sys 1115950143 173664
 386/bin/vtdump - 775 sys sys 1119496667 159467
 386/bin/wc - 775 sys sys 1115950143 41156
-386/bin/webcookies - 775 sys sys 1119496667 161521
-386/bin/webfs - 775 sys sys 1124766766 349594
+386/bin/webcookies - 775 sys sys 1124939607 161634
+386/bin/webfs - 775 sys sys 1124939607 349707
 386/bin/webfsget - 775 sys sys 1115950144 39143
-386/bin/wikifs - 775 sys sys 1122347400 201648
+386/bin/wikifs - 775 sys sys 1124939608 201761
 386/bin/winwatch - 775 sys sys 1115950145 154555
 386/bin/xd - 775 sys sys 1115950145 64039
 386/bin/xmr - 775 sys sys 1115950145 40157
@@ -533,7 +533,7 @@
 386/lib/ape/libregexp.a - 664 sys sys 1122001337 47670
 386/lib/ape/libutf.a - 664 sys sys 1122001338 81266
 386/lib/ape/libv.a - 664 sys sys 1122001338 19668
-386/lib/lib9p.a - 664 sys sys 1115950150 79300
+386/lib/lib9p.a - 664 sys sys 1124939608 79582
 386/lib/libString.a - 664 sys sys 1115950150 22184
 386/lib/libauth.a - 664 sys sys 1115950150 56134
 386/lib/libauthsrv.a - 664 sys sys 1117249746 34098
@@ -625,7 +625,7 @@ acme/bin/386/acd - 775 sys sys 1032232412 137068
 acme/bin/386/adict - 775 sys sys 1015011247 99806
 acme/bin/386/mkwnew - 775 sys sys 1115950148 38959
 acme/bin/386/spout - 775 sys sys 1115950148 61617
-acme/bin/386/win - 775 sys sys 1115950148 178845
+acme/bin/386/win - 775 sys sys 1124939608 178958
 acme/bin/Battery - 775 sys sys 1017457907 451
 acme/bin/Isspam - 775 sys sys 1063951165 235
 acme/bin/Mail - 775 sys sys 1114697798 201
@@ -2969,7 +2969,7 @@ lib/font/bit/lucidasans/typeunicode.9.font - 464 sys sys 1115917409 1678
 lib/font/bit/lucidasans/unicode.10.font - 664 sys sys 1115914025 2042
 lib/font/bit/lucidasans/unicode.13.font - 664 sys sys 1116086405 1898
 lib/font/bit/lucidasans/unicode.6.font - 664 sys sys 1115914026 1945
-lib/font/bit/lucidasans/unicode.7.font - 664 sys sys 1115914026 1988
+lib/font/bit/lucidasans/unicode.7.font - 664 sys sys 1124884861 2042
 lib/font/bit/lucidasans/unicode.8.font - 664 sys sys 1115917409 2095
 lib/font/bit/lucidasans/unicode.8.font1 - 664 sys sys 944943795 476
 lib/font/bit/lucidasans/unicode.9x24.font - 664 sys sys 944943794 1922
@@ -5250,6 +5250,7 @@ mail/lib/smtpd.conf.ext - 664 upas upas 1089299188 1032
 mail/lib/spam.rc - 775 upas upas 1063950954 400
 mail/lib/unspam.rc - 775 upas upas 1063950954 400
 mail/lib/validateaddress - 775 upas upas 1098803974 48
+mail/lib/validateattachment - 775 upas upas 1124885063 680
 mail/lib/validatesender - 775 upas upas 1106233741 1128
 mail/lib/white.starter - 664 upas upas 1067739606 326
 mail/queue - 20000000777 upas upas 953302652 0
@@ -5763,7 +5764,7 @@ sys/games - 20000000775 sys sys 952648872 0
 sys/games/lib - 20000000775 sys sys 952648879 0
 sys/games/lib/4scores - 10000000664 sys sys 1118680448 0
 sys/games/lib/5scores - 10000000664 sys sys 1118680453 0
-sys/games/lib/fortunes - 664 sys sys 1124716792 255238
+sys/games/lib/fortunes - 664 sys sys 1124931511 255388
 sys/games/lib/mahjongg - 20000000775 sys sys 1095792278 0
 sys/games/lib/mahjongg/backgrounds - 20000000775 sys sys 1095792293 0
 sys/games/lib/mahjongg/backgrounds/default.bit - 664 sys sys 1095792293 346803
@@ -7276,7 +7277,7 @@ sys/man/1/expect - 664 sys sys 1058791094 3023
 sys/man/1/faces - 664 sys sys 1113743326 2395
 sys/man/1/factor - 664 sys sys 957920005 1019
 sys/man/1/file - 664 sys sys 1015024739 1578
-sys/man/1/filter - 664 sys sys 1041108741 4403
+sys/man/1/filter - 664 sys sys 1124885098 4619
 sys/man/1/fmt - 664 sys sys 1070032221 1557
 sys/man/1/fortune - 664 sys sys 944959673 449
 sys/man/1/freq - 664 sys sys 944959673 735
@@ -8085,7 +8086,7 @@ sys/src/9/port/mkdevlist - 775 sys sys 1055700519 510
 sys/src/9/port/mkerrstr - 775 sys sys 1015278340 75
 sys/src/9/port/mkextract - 775 sys sys 1039753334 435
 sys/src/9/port/mkfile - 664 sys sys 1063856960 350
-sys/src/9/port/mkfilelist - 775 sys sys 1109202242 203
+sys/src/9/port/mkfilelist - 775 sys sys 1124890427 266
 sys/src/9/port/mkroot - 775 sys sys 1039753334 235
 sys/src/9/port/mkrootall - 775 sys sys 1055954696 386
 sys/src/9/port/mkrootc - 775 sys sys 1055954695 717
@@ -9522,7 +9523,7 @@ sys/src/cmd/aux/flashfs/entry.c - 664 sys sys 1015009081 7936
 sys/src/cmd/aux/flashfs/errors.c - 664 sys sys 1015009081 286
 sys/src/cmd/aux/flashfs/flash.c - 664 sys sys 1015009081 973
 sys/src/cmd/aux/flashfs/flashfs.h - 664 sys sys 1015092280 3422
-sys/src/cmd/aux/flashfs/journal.c - 664 sys sys 1015009081 14297
+sys/src/cmd/aux/flashfs/journal.c - 664 sys sys 1124916236 14317
 sys/src/cmd/aux/flashfs/mkfile - 664 sys sys 1015009082 649
 sys/src/cmd/aux/flashfs/mkfs.c - 664 sys sys 1015009082 1072
 sys/src/cmd/aux/flashfs/mkit - 775 sys sys 1015009082 86
@@ -9548,7 +9549,7 @@ sys/src/cmd/aux/mnihongo/mnihongo.c - 664 sys sys 946759402 6406
 sys/src/cmd/aux/mnihongo/tmac.nihongo - 664 sys sys 944960789 22
 sys/src/cmd/aux/mouse.c - 664 sys sys 1063855425 7049
 sys/src/cmd/aux/ms2.c - 664 sys sys 1124305056 3153
-sys/src/cmd/aux/msexceltables.c - 664 sys sys 1124709007 13935
+sys/src/cmd/aux/msexceltables.c - 664 sys sys 1124933681 13912
 sys/src/cmd/aux/mswordstrings.c - 664 sys sys 952201344 5767
 sys/src/cmd/aux/na - 20000000775 sys sys 955036627 0
 sys/src/cmd/aux/na/mkfile - 664 sys sys 955036627 121
@@ -9584,7 +9585,7 @@ sys/src/cmd/aux/vga/error.c - 664 sys sys 1014925008 745
 sys/src/cmd/aux/vga/et4000.c - 664 sys sys 1014925008 6720
 sys/src/cmd/aux/vga/et4000hwgc.c - 664 sys sys 1014925008 552
 sys/src/cmd/aux/vga/hiqvideo.c - 664 sys sys 1048635653 9211
-sys/src/cmd/aux/vga/i81x.c - 664 sys sys 1062391404 11759
+sys/src/cmd/aux/vga/i81x.c - 664 sys sys 1124916404 11755
 sys/src/cmd/aux/vga/ibm8514.c - 664 sys sys 1014925009 2389
 sys/src/cmd/aux/vga/icd2061a.c - 664 sys sys 1014925009 2152
 sys/src/cmd/aux/vga/ics2494.c - 664 sys sys 1014925009 2000
@@ -11866,7 +11867,7 @@ sys/src/cmd/gzip - 20000000775 sys sys 984789976 0
 sys/src/cmd/gzip/gunzip.c - 664 sys sys 1014924864 6039
 sys/src/cmd/gzip/gzip.c - 664 sys sys 1014924864 3646
 sys/src/cmd/gzip/gzip.h - 664 sys sys 954778718 1058
-sys/src/cmd/gzip/mkfile - 664 sys sys 984758036 125
+sys/src/cmd/gzip/mkfile - 664 sys sys 1124884920 124
 sys/src/cmd/gzip/unzip.c - 664 sys sys 1124839686 13816
 sys/src/cmd/gzip/zip.c - 664 sys sys 1033183074 7054
 sys/src/cmd/gzip/zip.h - 664 sys sys 954778719 1428
@@ -11918,7 +11919,7 @@ sys/src/cmd/ip/ftpfs/file.c - 664 sys sys 1014925642 4208
 sys/src/cmd/ip/ftpfs/ftpfs.c - 664 sys sys 1116737713 13860
 sys/src/cmd/ip/ftpfs/ftpfs.h - 664 sys sys 1091904423 2353
 sys/src/cmd/ip/ftpfs/mkfile - 664 sys sys 1048312050 173
-sys/src/cmd/ip/ftpfs/proto.c - 664 sys sys 1112563713 30346
+sys/src/cmd/ip/ftpfs/proto.c - 664 sys sys 1124935667 30337
 sys/src/cmd/ip/glob.c - 664 sys sys 1101155057 3290
 sys/src/cmd/ip/glob.h - 664 sys sys 1101155058 308
 sys/src/cmd/ip/gping.c - 664 sys sys 1015013112 20476
@@ -11965,7 +11966,7 @@ sys/src/cmd/ip/imap4d/nodes.c - 664 sys sys 1015013077 3173
 sys/src/cmd/ip/imap4d/search.c - 664 sys sys 1015013077 4520
 sys/src/cmd/ip/imap4d/store.c - 664 sys sys 1066317059 1910
 sys/src/cmd/ip/imap4d/utils.c - 664 sys sys 1015013077 2481
-sys/src/cmd/ip/ipconfig.c - 664 sys sys 1084471140 34896
+sys/src/cmd/ip/ipconfig.c - 664 sys sys 1124936750 34907
 sys/src/cmd/ip/measure.c - 664 sys sys 944961011 3733
 sys/src/cmd/ip/mkfile - 664 sys sys 1089739069 1232
 sys/src/cmd/ip/ping.c - 664 sys sys 1084471009 5651
@@ -13411,7 +13412,7 @@ sys/src/cmd/upas/unesc/mkfile - 664 sys sys 1075080255 164
 sys/src/cmd/upas/unesc/unesc.c - 664 sys sys 1075080255 789
 sys/src/cmd/upas/vf - 20000000775 sys sys 1015096796 0
 sys/src/cmd/upas/vf/mkfile - 664 sys sys 1064393881 241
-sys/src/cmd/upas/vf/vf.c - 664 sys sys 1102093227 17450
+sys/src/cmd/upas/vf/vf.c - 664 sys sys 1124885103 20004
 sys/src/cmd/usb - 20000000775 sys sys 1017802022 0
 sys/src/cmd/usb/audio - 20000000775 sys sys 1017802021 0
 sys/src/cmd/usb/audio/audiofs.c - 664 sys sys 1100568596 18166
@@ -13866,7 +13867,7 @@ sys/src/lib9p/post.c - 664 sys sys 1103565871 356
 sys/src/lib9p/post.h - 664 sys sys 1029850260 201
 sys/src/lib9p/ramfs.c - 664 sys sys 1030450927 2534
 sys/src/lib9p/req.c - 664 sys sys 1089299187 1652
-sys/src/lib9p/srv.c - 664 sys sys 1050583820 16705
+sys/src/lib9p/srv.c - 664 sys sys 1124911050 16885
 sys/src/lib9p/tpost.c - 664 sys sys 1103565872 316
 sys/src/lib9p/uid.c - 664 sys sys 1015023311 517
 sys/src/lib9p/util.c - 664 sys sys 1017679319 465
@@ -14800,7 +14801,7 @@ sys/src/libsec/port/sha1pickle.c - 664 sys sys 988225292 717
 sys/src/libsec/port/smallprimes.c - 664 sys sys 984710525 6851
 sys/src/libsec/port/smallprimetest.c - 664 sys sys 984710525 70640
 sys/src/libsec/port/thumb.c - 664 sys sys 1019832052 1891
-sys/src/libsec/port/tlshand.c - 664 sys sys 1124709122 54987
+sys/src/libsec/port/tlshand.c - 664 sys sys 1124935566 54999
 sys/src/libsec/port/x509.c - 664 sys sys 1063853597 50342
 sys/src/libsec/power - 20000000775 sys sys 984710502 0
 sys/src/libsec/power/mkfile - 664 sys sys 1032061453 139

+ 45 - 0
dist/replica/plan9.log

@@ -20851,3 +20851,48 @@
 1124839955 0 c sys/man/1/gzip - 664 sys sys 1124839836 3226
 1124839955 1 c sys/src/cmd/gzip/unzip.c - 664 sys sys 1124839686 13816
 1124854358 0 c 386/bin/unzip - 775 sys sys 1124853144 89971
+1124857959 0 c 386/9loaddebug - 775 sys sys 1124856571 310547
+1124857959 1 c 386/9pc - 775 sys sys 1124856576 1836888
+1124857959 2 c 386/9pccpu - 775 sys sys 1124856579 1491144
+1124857959 3 c 386/9pcdisk - 775 sys sys 1124856583 2042686
+1124857959 4 c 386/9pcf - 775 sys sys 1124856588 2385510
+1124857959 5 c 386/bin/unzip - 775 sys sys 1124856570 89971
+1124884965 0 c lib/font/bit/lucidasans/unicode.7.font - 664 sys sys 1124884861 2042
+1124884965 1 c sys/src/cmd/gzip/mkfile - 664 sys sys 1124884920 124
+1124886765 0 a mail/lib/validateattachment - 775 upas upas 1124885063 680
+1124886765 1 c sys/man/1/filter - 664 sys sys 1124885098 4619
+1124886765 2 c sys/src/cmd/upas/vf/vf.c - 664 sys sys 1124885103 20004
+1124892165 0 c sys/src/9/port/mkfilelist - 775 sys sys 1124890427 266
+1124911971 0 c sys/src/lib9p/srv.c - 664 sys sys 1124911050 16885
+1124917372 0 c sys/src/cmd/aux/flashfs/journal.c - 664 sys sys 1124916236 14317
+1124917372 1 c sys/src/cmd/aux/vga/i81x.c - 664 sys sys 1124916404 11755
+1124931775 0 c sys/games/lib/fortunes - 664 sys sys 1124931511 255388
+1124935376 0 c sys/src/cmd/aux/msexceltables.c - 664 sys sys 1124933681 13912
+1124937176 0 c sys/src/cmd/ip/ftpfs/proto.c - 664 sys sys 1124935667 30337
+1124937176 1 c sys/src/cmd/ip/ipconfig.c - 664 sys sys 1124936750 34907
+1124937176 2 c sys/src/libsec/port/tlshand.c - 664 sys sys 1124935566 54999
+1124940777 0 c 386/bin/archfs - 775 sys sys 1124939596 140892
+1124940777 1 c 386/bin/cdfs - 775 sys sys 1124939600 161202
+1124940777 2 c 386/bin/nntpfs - 775 sys sys 1124939604 161027
+1124940777 3 c 386/bin/snapfs - 775 sys sys 1124939605 372687
+1124940777 4 c 386/bin/webcookies - 775 sys sys 1124939607 161634
+1124940777 5 c 386/bin/wikifs - 775 sys sys 1124939608 201761
+1124940777 6 c 386/bin/rdbfs - 775 sys sys 1124939604 168509
+1124940777 7 c 386/bin/webfs - 775 sys sys 1124939607 349707
+1124940777 8 c 386/bin/auth/factotum - 775 sys sys 1124939596 312512
+1124940777 9 c 386/bin/aux/apm - 775 sys sys 1124939597 174208
+1124940777 10 c 386/bin/aux/disksim - 775 sys sys 1124939597 144461
+1124940777 11 c 386/bin/aux/flashfs - 775 sys sys 1124939598 160399
+1124940777 12 c 386/bin/aux/gpsfs - 775 sys sys 1124939598 176225
+1124940777 13 c 386/bin/aux/msexceltables - 775 sys sys 1124939598 81233
+1124940777 14 c 386/bin/aux/olefs - 775 sys sys 1124939599 143372
+1124940777 15 c 386/bin/aux/stub - 775 sys sys 1124939599 135175
+1124940777 16 c 386/bin/aux/vga - 775 sys sys 1124939600 333559
+1124940777 17 c 386/bin/execnet - 775 sys sys 1124939601 172009
+1124940777 18 c 386/bin/ext2srv - 775 sys sys 1124939601 174007
+1124940777 19 c 386/bin/mntgen - 775 sys sys 1124939602 139306
+1124940777 20 c 386/bin/nfs - 775 sys sys 1124939603 315518
+1124940777 21 c 386/bin/sshnet - 775 sys sys 1124939606 282851
+1124940777 22 c 386/bin/upas/vf - 775 sys sys 1124939606 97002
+1124940777 23 c 386/lib/lib9p.a - 664 sys sys 1124939608 79582
+1124940777 24 c acme/bin/386/win - 775 sys sys 1124939608 178958

+ 2 - 0
lib/font/bit/lucidasans/unicode.7.font

@@ -11,6 +11,8 @@
 0x2400	0x2424	../lucida/control.6.0
 0x2591	0x2593	../lucida/Altshades.6.0
 0x2500	0x25ee	../lucida/FormBlock.6.0
+0x2600	0x266F	../misc/ding
+0x2700	0x27BF	../misc/zapf
 0x3000 0x30fe ../shinonome/k12.3000
 0x4e00 0x4ffe ../shinonome/k12.4e00
 0x5005 0x51fe ../shinonome/k12.5005

+ 43 - 0
mail/lib/validateattachment

@@ -0,0 +1,43 @@
+#!/bin/rc
+
+# exit status matching:
+#
+#	*discard* - is really bad, refuse the message 
+#	*accept* - is really good, leave attachment alone
+#	* - rewrite attachment to have .suspect extension
+# 
+
+if(! ~ $#* 1){
+	echo usage: validateattachment mboxfile >[1=2]
+	exit usage
+}
+
+echo validating >[1=2]
+
+upas/fs -f $1
+cd /mail/fs/mbox/1
+
+x=`{file body}
+x=$"x
+switch($x){
+case *Ascii* *text* *'c program'* *'rc executable'* 
+	exit accept
+
+case *'zip archive'*
+	if(unzip -tsf body | grep -si '      |\.(scr|exe|pif|bat|com)$'){
+		echo executables inside zip file!
+		exit discard
+	}
+
+case *Microsoft* *Office*
+	exit wrap
+
+case *MSDOS*
+	# no executables
+	echo $x
+	exit discard
+}
+
+exit wrap
+
+

+ 1 - 0
sys/games/lib/fortunes

@@ -4078,3 +4078,4 @@ Arguing that Java is better than C++ is like arguing that grasshoppers taste bet
 (Of course SML does have its weaknesses, but by comparison, a discussion of C++'s strengths and flaws always sounds like an argument about whether one should face north or east when one is sacrificing one's goat to the rain god.)  - Thant Tessman
 C++ is history repeated as tragedy.  Java is history repeated as farce.  - Scott McKay
 Applicants must also have extensive knowledge of UNIX, although they should have sufficiently good programming taste to not consider this an achievement.  - Hal Abelson, MIT AI Lab job ad
+I recently visited plan9.bell-labs.com/wiki/plan9 and I would like to offer my web design services.  I can help you with your Plan 9 website.  - spam

+ 9 - 1
sys/man/1/filter

@@ -175,10 +175,15 @@ to any related filenames.
 .B /sys/lib/mimetype
 contains the list of known MIME content types and file extensions.
 .I Vf
-wraps all those for which the fifth field of
+considers all those for which the fifth field of
 .B mimetype
 is
 .BR n .
+If the script
+.B /mail/lib/validateattachment
+exists and is executable, each attachment
+is passed, as a mail message, to the script
+for further examination.
 .SH FILES
 .TF /mail/box/*/dead.letter
 .TP
@@ -187,6 +192,9 @@ mail filter
 .TP
 .B /sys/lib/mimetype
 mime content types
+.TP
+.B /mail/lib/validateattachment
+attachment checker
 .SH SOURCE
 .TP
 .B /sys/src/cmd/upas/send

+ 4 - 1
sys/src/9/port/mkfilelist

@@ -4,7 +4,10 @@ rfork e
 switch($#*){
 case 1
 	RE=`{echo *.c | sed 's/ /|/g; s/.*/^(&)$/'}
-	LIST=`{builtin cd $1; ls *.c | grep -v ''$RE''}
+	if(~ $RE '^(*.c)$')
+		LIST=`{builtin cd $1; ls *.c }
+	if not
+		LIST=`{builtin cd $1; ls *.c | grep -v ''$RE''}
 	echo $LIST | sed 's/\.c//g; s/ +/|/g'
 case *
 	exit 'usage'

+ 2 - 0
sys/src/cmd/aux/flashfs/journal.c

@@ -81,6 +81,8 @@ lddisc(char *mesg)
 {
 	if(debug)
 		fprint(2, "discard %s\n", mesg);
+	else
+		USED(mesg);
 }
 
 static Sect *

+ 0 - 1
sys/src/cmd/aux/msexceltables.c

@@ -343,7 +343,6 @@ xd(Biff *b)
 		Bprint(bo, "\n");
 	}
 	Bseek(b->bp, off, 0);
-	off = Boffset(b->bp);
 }
 
 static int 

+ 1 - 1
sys/src/cmd/aux/vga/i81x.c

@@ -106,7 +106,7 @@ static void
 i81xdclk(I81x *i81x, Vga *vga)		/* freq = MHz */
 {
 	int m, n, post, mtp, ntp;
-	double md, freq, error=1.0;
+	double md, freq, error;
 
 	freq = vga->mode->deffrequency/1000000.0;
 	post = log(600.0/freq)/log(2.0);

+ 1 - 1
sys/src/cmd/gzip/mkfile

@@ -10,6 +10,6 @@ TARG=\
 	zip\
 	unzip\
 
-BIN=/$objtype/bin/
+BIN=/$objtype/bin
 
 </sys/src/cmd/mkmany

+ 0 - 1
sys/src/cmd/ip/ftpfs/proto.c

@@ -63,7 +63,6 @@ hello(char *dest)
 {
 	char *p;
 	char dir[Maxpath];
-	int ts;
 	TLSconn conn;
 
 	Binit(&stdin, 0, OREAD);	/* init for later use */

+ 4 - 2
sys/src/cmd/ip/ipconfig.c

@@ -1653,6 +1653,7 @@ ndbconfig(void)
 int
 addoption(char *opt)
 {
+	int i;
 	Option *o;
 
 	if(opt == nil)
@@ -1661,9 +1662,10 @@ addoption(char *opt)
 		if(o->name == nil)
 			continue;
 		if(strcmp(opt, o->name) == 0){
-			if(!memchr(requested, (int)opt, nrequested))
+			i = o-option;
+			if(!memchr(requested, i, nrequested))
 				if(nrequested < nelem(requested))
-					requested[nrequested++] = o-option;
+					requested[nrequested++] = i;
 			return 0;
 		}
 	}

+ 159 - 29
sys/src/cmd/upas/vf/vf.c

@@ -32,12 +32,12 @@ static Part*	problemchild(Part *p);
 static void	readheader(Part *p);
 static Hline*	readhl(void);
 static void	readmtypes(void);
-static void	save(Part *p);
+static int	save(Part *p, char *file);
 static void	setfilename(Part *p, char *name);
 static char*	skiptosemi(char *p);
 static char*	skipwhite(char *p);
 static String*	tokenconvert(String *t);
-static void	writeheader(Part *p);
+static void	writeheader(Part *p, int);
 
 enum
 {
@@ -70,7 +70,8 @@ struct Part
 	int	blen;
 	String	*charset;	/* character set */
 	String	*type;		/* content type */
-	String	*filename;	/* content type */
+	String	*filename;	/* file name */
+	Biobuf	*tmpbuf;		/* diversion input buffer */
 };
 
 /*
@@ -144,6 +145,14 @@ main(int argc, char **argv)
 	exits(0);
 }
 
+void
+refuse(void)
+{
+	postnote(PNGROUP, getpid(), "mail refused: we don't accept executable attachments");
+	exits("mail refused: we don't accept executable attachments");
+}
+
+
 /*
  *  parse a part; returns the ancestor whose boundary terminated
  *  this part or nil on EOF.
@@ -167,7 +176,7 @@ part(Part *pp)
 		 *   boundary
 		 *   ...
 		 */
-		writeheader(p);
+		writeheader(p, 1);
 		np = passbody(p, 1);
 		if(np != p)
 			return np;
@@ -185,29 +194,31 @@ part(Part *pp)
 			 *   header
 			 *   body
 			 */
-			writeheader(p);
+			writeheader(p, 1);
 			passnotheader();
 			return part(p);
 		} else {
-			/* This is the meat.  This may be an executable.
+			/* 
+			 * This is the meat.  This may be an executable.
 			 * if so, wrap it and change its type
 			 */
 			if(p->badtype || p->badfile){
 				if(p->badfile == 2){
 					if(savefile != nil)
-						save(p);
+						save(p, savefile);
 					syslog(0, "vf", "vf rejected %s %s", p->type?s_to_c(p->type):"?",
 						p->filename?s_to_c(p->filename):"?");
 					fprint(2, "The mail contained an executable attachment.\n");
 					fprint(2, "We refuse all mail containing such.\n");
-					postnote(PNGROUP, getpid(), "mail refused: we don't accept executable attachments");
-					exits("mail refused: we don't accept executable attachments");
+					refuse();
 				}
-				return problemchild(p);
-			} else {
-				writeheader(p);
-				return passbody(p, 1);
+				np = problemchild(p);
+				if(np != p)
+					return np;
+				/* if problemchild returns p, it turns out p is okay: fall thru */
 			}
+			writeheader(p, 1);
+			return passbody(p, 1);
 		}
 	}
 }
@@ -279,17 +290,20 @@ readhl(void)
  *  write out a complete header
  */
 static void
-writeheader(Part *p)
+writeheader(Part *p, int xfree)
 {
 	Hline *hl, *next;
 
 	for(hl = p->hl; hl != nil; hl = next){
 		Bprint(&out, "%s", s_to_c(hl->s));
-		s_free(hl->s);
+		if(xfree)
+			s_free(hl->s);
 		next = hl->next;
-		free(hl);
+		if(xfree)
+			free(hl);
 	}
-	p->hl = nil;
+	if(xfree)
+		p->hl = nil;
 }
 
 /*
@@ -301,22 +315,35 @@ static Part*
 passbody(Part *p, int dobound)
 {
 	Part *pp;
+	Biobuf *b;
 	char *cp;
 
 	for(;;){
-		cp = Brdline(&in, '\n');
+		if(p->tmpbuf){
+			b = p->tmpbuf;
+			cp = Brdline(b, '\n');
+			if(cp == nil){
+				Bterm(b);
+				p->tmpbuf = nil;
+				goto Stdin;
+			}
+		}else{
+		Stdin:
+			b = &in;
+			cp = Brdline(b, '\n');
+		}
 		if(cp == nil)
 			return nil;
 		for(pp = p; pp != nil; pp = pp->pp)
 			if(pp->boundary != nil
 			&& strncmp(cp, s_to_c(pp->boundary), pp->blen) == 0){
 				if(dobound)
-					Bwrite(&out, cp, Blinelen(&in));
+					Bwrite(&out, cp, Blinelen(b));
 				else
-					Bseek(&in, -Blinelen(&in), 1);
+					Bseek(b, -Blinelen(b), 1);
 				return pp;
 			}
-		Bwrite(&out, cp, Blinelen(&in));
+		Bwrite(&out, cp, Blinelen(b));
 	}
 	return nil;
 }
@@ -324,8 +351,9 @@ passbody(Part *p, int dobound)
 /*
  *  save the message somewhere
  */
-static void
-save(Part *p)
+static vlong bodyoff;	/* clumsy hack */
+static int
+save(Part *p, char *file)
 {
 	int fd;
 	char *cp;
@@ -333,19 +361,108 @@ save(Part *p)
 	Bterm(&out);
 	memset(&out, 0, sizeof(out));
 
-	fd = open(savefile, OWRITE);
+	fd = open(file, OWRITE);
 	if(fd < 0)
-		return;
+		return -1;
 	seek(fd, 0, 2);
 	Binit(&out, fd, OWRITE);
 	cp = ctime(time(0));
 	cp[28] = 0;
 	Bprint(&out, "From virusfilter %s\n", cp);
-	writeheader(p);
+	writeheader(p, 0);
+	bodyoff = Boffset(&out);
 	passbody(p, 1);
 	Bprint(&out, "\n");
 	Bterm(&out);
 	close(fd);
+	
+	memset(&out, 0, sizeof out);
+	Binit(&out, 1, OWRITE);
+	return 0;
+}
+
+/*
+ * write to a file but save the fd for passbody.
+ */
+static char*
+savetmp(Part *p)
+{
+	char buf[40], *name;
+	int fd;
+	
+	strcpy(buf, "/tmp/vf.XXXXXXXXXXX");
+	name = mktemp(buf);
+	if((fd = create(name, OWRITE|OEXCL, 0666)) < 0){
+		fprint(2, "error creating temporary file: %r\n");
+		refuse();
+	}
+	close(fd);
+	if(save(p, name) < 0){
+		fprint(2, "error saving temporary file: %r\n");
+		refuse();
+	}
+	if(p->tmpbuf){
+		fprint(2, "error in savetmp: already have tmp file!\n");
+		refuse();
+	}
+	p->tmpbuf = Bopen(name, OREAD|ORCLOSE);
+	if(p->tmpbuf == nil){
+		fprint(2, "error reading tempoary file: %r\n");
+		refuse();
+	}
+	Bseek(p->tmpbuf, bodyoff, 0);
+	return strdup(name);
+}
+
+/*
+ * XXX save the decoded file, run 9 unzip -tf on it, and then
+ * look at the file list.
+ */
+static int
+runchecker(Part *p)
+{
+	int pid;
+	char *name;
+	Waitmsg *w;
+	
+	if(access("/mail/lib/validateattachment", AEXEC) < 0)
+		return 0;
+	
+	name = savetmp(p);
+	fprint(2, "run checker %s\n", name);
+	switch(pid = fork()){
+	case -1:
+		sysfatal("fork: %r");
+	case 0:
+		dup(2, 1);
+		execl("/mail/lib/validateattachment", "validateattachment", name, nil);
+		_exits("exec failed");
+	}
+
+	/*
+	 * Okay to return on error - will let mail through but wrapped.
+	 */
+	w = wait();
+	if(w == nil){
+		syslog(0, "mail", "vf wait failed: %r");
+		return 0;
+	}
+	if(w->pid != pid){
+		syslog(0, "mail", "vf wrong pid %d != %d", w->pid, pid);
+		return 0;
+	}
+	if(p->filename)
+		name = s_to_c(p->filename);
+	if(strstr(w->msg, "discard")){
+		syslog(0, "mail", "vf validateattachment rejected %s", name);
+		refuse();
+	}
+	if(strstr(w->msg, "accept")){
+		syslog(0, "mail", "vf validateattachment accepted %s", name);
+		return 1;
+	}
+	free(w);
+	return 0;
 }
 
 /*
@@ -359,17 +476,27 @@ problemchild(Part *p)
 	String *boundary;
 	char *cp;
 
+	/*
+	 * We don't know whether the attachment is okay.
+	 * If there's an external checker, let it have a crack at it.
+	 */
+	if(runchecker(p) > 0)
+		return p;
+
+fprint(2, "x\n");
 	syslog(0, "mail", "vf wrapped %s %s", p->type?s_to_c(p->type):"?",
 		p->filename?s_to_c(p->filename):"?");
+fprint(2, "x\n");
 
 	boundary = mkboundary();
-
+fprint(2, "x\n");
 	/* print out non-mime headers */
 	for(hl = p->hl; hl != nil; hl = hl->next)
 		if(cistrncmp(s_to_c(hl->s), "content-", 8) != 0)
 			Bprint(&out, "%s", s_to_c(hl->s));
 
-	/* add in out own multipart headers and message */
+fprint(2, "x\n");
+	/* add in our own multipart headers and message */
 	Bprint(&out, "Content-Type: multipart/mixed;\n");
 	Bprint(&out, "\tboundary=\"%s\"\n", s_to_c(boundary));
 	Bprint(&out, "Content-Disposition: inline\n");
@@ -412,16 +539,19 @@ problemchild(Part *p)
 		break;
 	}
 
+fprint(2, "z\n");
 	/* pass the body */
 	np = passbody(p, 0);
 
+fprint(2, "w\n");
 	/* add the new boundary and the original terminator */
 	Bprint(&out, "--%s--\n", s_to_c(boundary));
 	if(np && np->boundary){
 		cp = Brdline(&in, '\n');
 		Bwrite(&out, cp, Blinelen(&in));
 	}
-	
+
+fprint(2, "a %p\n", np);
 	return np;
 }
 

+ 10 - 0
sys/src/lib9p/srv.c

@@ -724,6 +724,16 @@ srv(Srv *srv)
 		}
 	}
 
+	free(srv->rbuf);
+	srv->rbuf = nil;
+	free(srv->wbuf);
+	srv->wbuf = nil;
+	srv->msize = 0;
+	freefidpool(srv->fpool);
+	srv->fpool = nil;
+	freereqpool(srv->rpool);
+	srv->rpool = nil;
+
 	if(srv->end)
 		srv->end(srv);
 }

+ 1 - 0
sys/src/libsec/port/tlshand.c

@@ -1154,6 +1154,7 @@ msgRecv(TlsConnection *c, Msg *m)
 		if(nn == 0 || n != nn)
 			goto Short;
 		 */
+		USED(nn);
 		/* cas */
 		i = 0;
 		while(n > 0) {