Date: Mon, 23 Apr 2007 14:44:37 GMT From: Robert Watson <rwatson@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 118666 for review Message-ID: <200704231444.l3NEibbh061754@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=118666 Change 118666 by rwatson@rwatson_zoo on 2007/04/23 14:44:18 Integrate TrustedBSD audit3 branch from TrustedBSD base branch. Affected files ... .. //depot/projects/trustedbsd/audit3/ObsoleteFiles.inc#15 integrate .. //depot/projects/trustedbsd/audit3/UPDATING#21 integrate .. //depot/projects/trustedbsd/audit3/compat/opensolaris/misc/fsshare.c#2 integrate .. //depot/projects/trustedbsd/audit3/contrib/opensolaris/cmd/zdb/zdb.c#2 integrate .. //depot/projects/trustedbsd/audit3/contrib/opensolaris/lib/libzfs/common/libzfs_changelist.c#2 integrate .. //depot/projects/trustedbsd/audit3/contrib/opensolaris/lib/libzfs/common/libzfs_config.c#2 integrate .. //depot/projects/trustedbsd/audit3/contrib/opensolaris/lib/libzfs/common/libzfs_import.c#3 integrate .. //depot/projects/trustedbsd/audit3/contrib/top/top.c#6 integrate .. //depot/projects/trustedbsd/audit3/etc/rc.d/zfs#3 integrate .. //depot/projects/trustedbsd/audit3/lib/libarchive/archive_write_disk_set_standard_lookup.c#2 integrate .. //depot/projects/trustedbsd/audit3/lib/libc/net/rthdr.c#3 integrate .. //depot/projects/trustedbsd/audit3/lib/libc/stdio/fputs.3#4 integrate .. //depot/projects/trustedbsd/audit3/lib/libfetch/fetch.3#5 integrate .. //depot/projects/trustedbsd/audit3/lib/libfetch/ftp.c#6 integrate .. //depot/projects/trustedbsd/audit3/lib/libpthread/thread/thr_info.c#4 integrate .. //depot/projects/trustedbsd/audit3/libexec/ftpd/ftpd.8#7 integrate .. //depot/projects/trustedbsd/audit3/release/doc/en_US.ISO8859-1/relnotes/article.sgml#5 integrate .. //depot/projects/trustedbsd/audit3/sbin/fdisk_pc98/fdisk.8#5 integrate .. //depot/projects/trustedbsd/audit3/sbin/fdisk_pc98/fdisk.c#6 integrate .. //depot/projects/trustedbsd/audit3/sbin/ping6/ping6.c#4 integrate .. //depot/projects/trustedbsd/audit3/share/man/man4/Makefile#19 integrate .. //depot/projects/trustedbsd/audit3/share/man/man4/sbsh.4#3 integrate .. //depot/projects/trustedbsd/audit3/share/man/man4/worm.4#3 delete .. //depot/projects/trustedbsd/audit3/share/man/man8/nanobsd.8#3 integrate .. //depot/projects/trustedbsd/audit3/share/man/man9/pseudofs.9#3 integrate .. //depot/projects/trustedbsd/audit3/share/misc/committers-ports.dot#4 integrate .. //depot/projects/trustedbsd/audit3/share/misc/committers-src.dot#4 integrate .. //depot/projects/trustedbsd/audit3/share/misc/organization.dot#2 integrate .. //depot/projects/trustedbsd/audit3/share/mk/version_gen.awk#2 integrate .. //depot/projects/trustedbsd/audit3/sys/amd64/amd64/pmap.c#17 integrate .. //depot/projects/trustedbsd/audit3/sys/amd64/include/vmparam.h#3 integrate .. //depot/projects/trustedbsd/audit3/sys/cam/cam_periph.c#10 integrate .. //depot/projects/trustedbsd/audit3/sys/cam/cam_periph.h#5 integrate .. //depot/projects/trustedbsd/audit3/sys/cam/cam_xpt.c#14 integrate .. //depot/projects/trustedbsd/audit3/sys/cam/scsi/scsi_da.c#14 integrate .. //depot/projects/trustedbsd/audit3/sys/cam/scsi/scsi_pt.c#6 integrate .. //depot/projects/trustedbsd/audit3/sys/cam/scsi/scsi_sa.c#8 integrate .. //depot/projects/trustedbsd/audit3/sys/compat/linprocfs/linprocfs.c#14 integrate .. //depot/projects/trustedbsd/audit3/sys/compat/opensolaris/kern/opensolaris_misc.c#2 integrate .. //depot/projects/trustedbsd/audit3/sys/compat/opensolaris/kern/opensolaris_vfs.c#4 integrate .. //depot/projects/trustedbsd/audit3/sys/compat/opensolaris/sys/misc.h#2 integrate .. //depot/projects/trustedbsd/audit3/sys/compat/opensolaris/sys/sunddi.h#1 branch .. //depot/projects/trustedbsd/audit3/sys/compat/opensolaris/sys/types.h#2 integrate .. //depot/projects/trustedbsd/audit3/sys/compat/opensolaris/sys/vnode.h#2 integrate .. //depot/projects/trustedbsd/audit3/sys/conf/files#31 integrate .. //depot/projects/trustedbsd/audit3/sys/contrib/opensolaris/uts/common/fs/zfs/spa.c#4 integrate .. //depot/projects/trustedbsd/audit3/sys/contrib/opensolaris/uts/common/fs/zfs/spa_config.c#4 integrate .. //depot/projects/trustedbsd/audit3/sys/contrib/opensolaris/uts/common/fs/zfs/vdev.c#2 integrate .. //depot/projects/trustedbsd/audit3/sys/contrib/opensolaris/uts/common/fs/zfs/zap.c#3 integrate .. //depot/projects/trustedbsd/audit3/sys/contrib/opensolaris/uts/common/fs/zfs/zfs_ioctl.c#3 integrate .. //depot/projects/trustedbsd/audit3/sys/contrib/opensolaris/uts/common/fs/zfs/zfs_log.c#2 integrate .. //depot/projects/trustedbsd/audit3/sys/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c#5 integrate .. //depot/projects/trustedbsd/audit3/sys/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c#2 integrate .. //depot/projects/trustedbsd/audit3/sys/contrib/opensolaris/uts/common/fs/zfs/zfs_znode.c#3 integrate .. //depot/projects/trustedbsd/audit3/sys/contrib/opensolaris/uts/common/fs/zfs/zio.c#2 integrate .. //depot/projects/trustedbsd/audit3/sys/contrib/opensolaris/uts/common/fs/zfs/zvol.c#2 integrate .. //depot/projects/trustedbsd/audit3/sys/dev/aic7xxx/aic79xx.c#7 integrate .. //depot/projects/trustedbsd/audit3/sys/dev/aic7xxx/aic79xx.h#6 integrate .. //depot/projects/trustedbsd/audit3/sys/dev/aic7xxx/aic7xxx.c#5 integrate .. //depot/projects/trustedbsd/audit3/sys/dev/aic7xxx/aic7xxx.h#5 integrate .. //depot/projects/trustedbsd/audit3/sys/dev/aic7xxx/aic7xxx_inline.h#3 integrate .. //depot/projects/trustedbsd/audit3/sys/dev/ath/if_ath.c#17 integrate .. //depot/projects/trustedbsd/audit3/sys/dev/cxgb/cxgb_sge.c#4 integrate .. //depot/projects/trustedbsd/audit3/sys/dev/cxgb/sys/uipc_mvec.c#3 integrate .. //depot/projects/trustedbsd/audit3/sys/dev/led/led.c#4 integrate .. //depot/projects/trustedbsd/audit3/sys/dev/led/led.h#3 integrate .. //depot/projects/trustedbsd/audit3/sys/dev/sound/pci/envy24.c#6 integrate .. //depot/projects/trustedbsd/audit3/sys/dev/sound/pci/envy24ht.c#4 integrate .. //depot/projects/trustedbsd/audit3/sys/fs/devfs/devfs_devs.c#8 integrate .. //depot/projects/trustedbsd/audit3/sys/fs/devfs/devfs_vnops.c#12 integrate .. //depot/projects/trustedbsd/audit3/sys/fs/procfs/procfs_map.c#5 integrate .. //depot/projects/trustedbsd/audit3/sys/i386/i386/pmap.c#18 integrate .. //depot/projects/trustedbsd/audit3/sys/i386/i386/sys_machdep.c#7 integrate .. //depot/projects/trustedbsd/audit3/sys/i386/include/vmparam.h#4 integrate .. //depot/projects/trustedbsd/audit3/sys/ia64/include/vmparam.h#5 integrate .. //depot/projects/trustedbsd/audit3/sys/kern/kern_linker.c#10 integrate .. //depot/projects/trustedbsd/audit3/sys/kern/kern_malloc.c#11 integrate .. //depot/projects/trustedbsd/audit3/sys/kern/kern_time.c#11 integrate .. //depot/projects/trustedbsd/audit3/sys/kern/kern_uuid.c#7 integrate .. //depot/projects/trustedbsd/audit3/sys/kern/sched_ule.c#13 integrate .. //depot/projects/trustedbsd/audit3/sys/kern/uipc_syscalls.c#16 integrate .. //depot/projects/trustedbsd/audit3/sys/netgraph/ng_ppp.c#6 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/sctp.h#3 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/sctp_indata.c#6 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/sctp_indata.h#3 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/sctp_input.c#6 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/sctp_output.c#6 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/sctp_pcb.c#6 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/sctp_pcb.h#4 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/sctp_structs.h#6 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/sctp_uio.h#6 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/sctp_usrreq.c#6 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/sctputil.c#6 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/sctputil.h#6 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/tcp.h#7 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/tcp_input.c#18 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/tcp_output.c#11 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/tcp_syncache.c#16 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet/tcp_var.h#13 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet6/in6_pcb.c#10 integrate .. //depot/projects/trustedbsd/audit3/sys/netinet6/route6.c#4 integrate .. //depot/projects/trustedbsd/audit3/sys/nfsclient/nfs_lock.c#5 integrate .. //depot/projects/trustedbsd/audit3/sys/nfsserver/nfs_syscalls.c#10 integrate .. //depot/projects/trustedbsd/audit3/sys/pci/if_vr.c#11 integrate .. //depot/projects/trustedbsd/audit3/sys/pci/if_vrreg.h#9 integrate .. //depot/projects/trustedbsd/audit3/sys/pci/intpm.c#5 integrate .. //depot/projects/trustedbsd/audit3/sys/powerpc/powerpc/nexus.c#5 integrate .. //depot/projects/trustedbsd/audit3/sys/security/audit/audit_syscalls.c#36 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac/mac_audit.c#10 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac/mac_framework.h#8 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac/mac_inet.c#6 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac/mac_net.c#6 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac/mac_pipe.c#6 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac/mac_policy.h#8 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac/mac_process.c#7 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac/mac_socket.c#7 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac/mac_system.c#7 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac/mac_vfs.c#10 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac_biba/mac_biba.c#12 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac_bsdextended/mac_bsdextended.c#12 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac_ifoff/mac_ifoff.c#4 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac_lomac/mac_lomac.c#11 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac_mls/mac_mls.c#10 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac_partition/mac_partition.c#6 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac_portacl/mac_portacl.c#8 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac_seeotheruids/mac_seeotheruids.c#7 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac_stub/mac_stub.c#9 integrate .. //depot/projects/trustedbsd/audit3/sys/security/mac_test/mac_test.c#9 integrate .. //depot/projects/trustedbsd/audit3/sys/sparc64/include/vmparam.h#2 integrate .. //depot/projects/trustedbsd/audit3/sys/sun4v/include/vmparam.h#2 integrate .. //depot/projects/trustedbsd/audit3/sys/sys/mount.h#15 integrate .. //depot/projects/trustedbsd/audit3/sys/sys/priv.h#5 integrate .. //depot/projects/trustedbsd/audit3/tools/regression/netinet6/inet6_rth/Makefile#1 branch .. //depot/projects/trustedbsd/audit3/tools/regression/netinet6/inet6_rth/inet6_rth-segments.c#1 branch .. //depot/projects/trustedbsd/audit3/tools/regression/netinet6/inet6_rth/test_subr.c#1 branch .. //depot/projects/trustedbsd/audit3/tools/regression/netinet6/inet6_rth/test_subr.h#1 branch .. //depot/projects/trustedbsd/audit3/tools/regression/sockets/sendfile/sendfile.c#3 integrate .. //depot/projects/trustedbsd/audit3/tools/regression/usr.bin/sed/regress.sh#4 integrate .. //depot/projects/trustedbsd/audit3/tools/sched/schedgraph.py#5 integrate .. //depot/projects/trustedbsd/audit3/tools/tools/nanobsd/nanobsd.sh#9 integrate .. //depot/projects/trustedbsd/audit3/usr.bin/make/GNode.h#2 integrate .. //depot/projects/trustedbsd/audit3/usr.bin/make/main.c#9 integrate .. //depot/projects/trustedbsd/audit3/usr.bin/make/make.c#3 integrate .. //depot/projects/trustedbsd/audit3/usr.bin/make/targ.c#3 integrate .. //depot/projects/trustedbsd/audit3/usr.bin/sed/extern.h#3 integrate .. //depot/projects/trustedbsd/audit3/usr.bin/sed/main.c#5 integrate .. //depot/projects/trustedbsd/audit3/usr.bin/sed/process.c#6 integrate .. //depot/projects/trustedbsd/audit3/usr.bin/sed/sed.1#5 integrate .. //depot/projects/trustedbsd/audit3/usr.sbin/daemon/daemon.c#5 integrate .. //depot/projects/trustedbsd/audit3/usr.sbin/pmcstat/pmcstat.8#6 integrate .. //depot/projects/trustedbsd/audit3/usr.sbin/pmcstat/pmcstat.c#6 integrate .. //depot/projects/trustedbsd/audit3/usr.sbin/pmcstat/pmcstat.h#3 integrate Differences ... ==== //depot/projects/trustedbsd/audit3/ObsoleteFiles.inc#15 (text+ko) ==== @@ -1,5 +1,5 @@ # -# $FreeBSD: src/ObsoleteFiles.inc,v 1.79 2007/04/17 01:02:55 thompsa Exp $ +# $FreeBSD: src/ObsoleteFiles.inc,v 1.80 2007/04/20 23:47:30 brueffer Exp $ # # This file lists old files (OLD_FILES), libraries (OLD_LIBS) and # directories (OLD_DIRS) which should get removed at an update. Recently @@ -14,6 +14,8 @@ # The file is partitioned: OLD_FILES first, then OLD_LIBS and OLD_DIRS last. # +# 20070421: worm.4 removed +OLD_FILES+=usr/share/man/man4/worm.4.gz # 20070417: trunk(4) renamed to lagg(4) OLD_FILES+=usr/include/net/if_trunk.h # 20070409: uuidgen moved to /bin/ ==== //depot/projects/trustedbsd/audit3/UPDATING#21 (text+ko) ==== @@ -21,17 +21,6 @@ developers choose to disable these features on build machines to maximize performance. -20070418: - A new acct(5) format is imminent. If you want to maintain access - to your accounting files, use the new lastcomm(1) -X functionality to - export them into text format, and keep around a copy of the lastcomm - binary. An updated lastcomm(1) program will allow you to import - the text files into the new acct(5) format. The change will also - invalidate the condensed summary files /var/account/savacct and - /var/account/usracct. If your process accounting system relies - on them, you will need to save their contents in a readable format - before the switch. - 20070417: The new trunk(4) driver has been renamed to lagg(4) as it better reflects its purpose. ifconfig will need to be recompiled. @@ -778,4 +767,4 @@ Contact Warner Losh if you have any questions about your use of this document. -$FreeBSD: src/UPDATING,v 1.487 2007/04/18 17:34:59 dds Exp $ +$FreeBSD: src/UPDATING,v 1.488 2007/04/19 17:08:54 dds Exp $ ==== //depot/projects/trustedbsd/audit3/compat/opensolaris/misc/fsshare.c#2 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/compat/opensolaris/misc/fsshare.c,v 1.1 2007/04/06 01:08:59 pjd Exp $"); +__FBSDID("$FreeBSD: src/compat/opensolaris/misc/fsshare.c,v 1.2 2007/04/21 13:17:23 pjd Exp $"); #include <sys/param.h> #include <stdio.h> @@ -99,21 +99,30 @@ /* * Function translate options to a format acceptable by exports(5), eg. * - * -ro -network=192.168.0.0 -mask=255.255.255.0 -maproot=0 + * -ro -network=192.168.0.0 -mask=255.255.255.0 -maproot=0 freefall.freebsd.org 69.147.83.54 * * Accepted input formats: * - * ro,network=192.168.0.0,mask=255.255.255.0,maproot=0 - * ro network=192.168.0.0 mask=255.255.255.0 maproot=0 - * -ro,-network=192.168.0.0,-mask=255.255.255.0,-maproot=0 - * -ro -network=192.168.0.0 -mask=255.255.255.0 -maproot=0 + * ro,network=192.168.0.0,mask=255.255.255.0,maproot=0,freefall.freebsd.org + * ro network=192.168.0.0 mask=255.255.255.0 maproot=0 freefall.freebsd.org + * -ro,-network=192.168.0.0,-mask=255.255.255.0,-maproot=0,freefall.freebsd.org + * -ro -network=192.168.0.0 -mask=255.255.255.0 -maproot=0 freefall.freebsd.org + * + * Recognized keywords: + * + * ro, maproot, mapall, mask, network, alldirs, public, webnfs, index, quiet + * */ +static const char *known_opts[] = { "ro", "maproot", "mapall", "mask", + "network", "alldirs", "public", "webnfs", "index", "quiet", NULL }; static char * translate_opts(const char *shareopts) { static char newopts[OPTSSIZE]; - char oldopts[OPTSSIZE], opt[64]; + char oldopts[OPTSSIZE]; char *o, *s = NULL; + unsigned int i; + size_t len; strlcpy(oldopts, shareopts, sizeof(oldopts)); newopts[0] = '\0'; @@ -121,8 +130,16 @@ while ((o = strsep(&s, "-, ")) != NULL) { if (o[0] == '\0') continue; - snprintf(opt, sizeof(opt), "-%s ", o); - strlcat(newopts, opt, sizeof(newopts)); + for (i = 0; known_opts[i] != NULL; i++) { + len = strlen(known_opts[i]); + if (strncmp(known_opts[i], o, len) == 0 && + (o[len] == '\0' || o[len] == '=')) { + strlcat(newopts, "-", sizeof(newopts)); + break; + } + } + strlcat(newopts, o, sizeof(newopts)); + strlcat(newopts, " ", sizeof(newopts)); } return (newopts); } ==== //depot/projects/trustedbsd/audit3/contrib/opensolaris/cmd/zdb/zdb.c#2 (text+ko) ==== @@ -932,11 +932,11 @@ if (doi.doi_checksum != ZIO_CHECKSUM_INHERIT || verbosity >= 6) (void) snprintf(aux + strlen(aux), sizeof (aux), " (K=%s)", - zio_checksum_table[doi.doi_checksum].ci_name); + zio_checksum_table[doi.doi_checksum].ci_name); if (doi.doi_compress != ZIO_COMPRESS_INHERIT || verbosity >= 6) (void) snprintf(aux + strlen(aux), sizeof (aux), " (Z=%s)", - zio_compress_table[doi.doi_compress].ci_name); + zio_compress_table[doi.doi_compress].ci_name); (void) printf("%10lld %3u %5s %5s %5s %5s %s%s\n", (u_longlong_t)object, doi.doi_indirection, iblk, dblk, lsize, @@ -1441,7 +1441,7 @@ (u_longlong_t)zb->zb_objset, (u_longlong_t)zb->zb_object, (u_longlong_t)blkid2offset(bc->bc_dnode, - zb->zb_level, zb->zb_blkid), + zb->zb_level, zb->zb_blkid), blkbuf); } @@ -1951,8 +1951,8 @@ spa_close(spa, (void *)zdb_read_block); error = spa_open(spa_name, spap, (void *)zdb_read_block); if (error) - fatal("Failed to open pool '%s': errno = %d\n", - spa_name, error); + fatal("Failed to open pool '%s': %s", + spa_name, strerror(error)); spa = *spap; } @@ -2156,7 +2156,7 @@ } if (error) - fatal("can't open %s: error %d", argv[0], error); + fatal("can't open %s: %s", argv[0], strerror(error)); argv++; if (--argc > 0) { ==== //depot/projects/trustedbsd/audit3/contrib/opensolaris/lib/libzfs/common/libzfs_changelist.c#2 (text+ko) ==== @@ -339,22 +339,15 @@ changelist_free(prop_changelist_t *clp) { prop_changenode_t *cn; - uu_list_walk_t *walk; + void *cookie; if (clp->cl_list) { - verify((walk = uu_list_walk_start(clp->cl_list, - UU_WALK_ROBUST)) != NULL); - - while ((cn = uu_list_walk_next(walk)) != NULL) { - - uu_list_remove(clp->cl_list, cn); - + cookie = NULL; + while ((cn = uu_list_teardown(clp->cl_list, &cookie)) != NULL) { zfs_close(cn->cn_handle); free(cn); } - uu_list_walk_end(walk); - uu_list_destroy(clp->cl_list); } if (clp->cl_pool) @@ -418,7 +411,7 @@ } else { ASSERT(!clp->cl_alldependents); verify(uu_list_insert_before(clp->cl_list, - uu_list_first(clp->cl_list), cn) == 0); + uu_list_first(clp->cl_list), cn) == 0); } if (!clp->cl_alldependents) ==== //depot/projects/trustedbsd/audit3/contrib/opensolaris/lib/libzfs/common/libzfs_config.c#2 (text+ko) ==== @@ -74,22 +74,16 @@ namespace_clear(libzfs_handle_t *hdl) { if (hdl->libzfs_ns_avl) { - uu_avl_walk_t *walk; config_node_t *cn; + void *cookie = NULL; - if ((walk = uu_avl_walk_start(hdl->libzfs_ns_avl, - UU_WALK_ROBUST)) == NULL) - return; - - while ((cn = uu_avl_walk_next(walk)) != NULL) { - uu_avl_remove(hdl->libzfs_ns_avl, cn); + while ((cn = uu_avl_teardown(hdl->libzfs_ns_avl, + &cookie)) != NULL) { nvlist_free(cn->cn_config); free(cn->cn_name); free(cn); } - uu_avl_walk_end(walk); - uu_avl_destroy(hdl->libzfs_ns_avl); hdl->libzfs_ns_avl = NULL; } @@ -110,7 +104,7 @@ config_node_t *cn; nvpair_t *elem; zfs_cmd_t zc = { 0 }; - uu_avl_walk_t *walk; + void *cookie; if (hdl->libzfs_ns_gen == 0) { /* @@ -172,21 +166,13 @@ /* * Clear out any existing configuration information. */ - if ((walk = uu_avl_walk_start(hdl->libzfs_ns_avl, - UU_WALK_ROBUST)) == NULL) { - nvlist_free(config); - return (no_memory(hdl)); - } - - while ((cn = uu_avl_walk_next(walk)) != NULL) { - uu_avl_remove(hdl->libzfs_ns_avl, cn); + cookie = NULL; + while ((cn = uu_avl_teardown(hdl->libzfs_ns_avl, &cookie)) != NULL) { nvlist_free(cn->cn_config); free(cn->cn_name); free(cn); } - uu_avl_walk_end(walk); - elem = NULL; while ((elem = nvlist_next_nvpair(config, elem)) != NULL) { nvlist_t *child; @@ -222,7 +208,7 @@ } /* - * Retrive the configuration for the given pool. The configuration is a nvlist + * Retrieve the configuration for the given pool. The configuration is a nvlist * describing the vdevs, as well as the statistics associated with each one. */ nvlist_t * ==== //depot/projects/trustedbsd/audit3/contrib/opensolaris/lib/libzfs/common/libzfs_import.c#3 (text+ko) ==== @@ -220,7 +220,7 @@ &state) == 0 && state == POOL_STATE_SPARE && nvlist_lookup_uint64(config, ZPOOL_CONFIG_GUID, &vdev_guid) == 0) { if ((ne = zfs_alloc(hdl, sizeof (name_entry_t))) == NULL) - return (-1); + return (-1); if ((ne->ne_name = zfs_strdup(hdl, path)) == NULL) { free(ne); @@ -748,7 +748,6 @@ zpool_find_import(libzfs_handle_t *hdl, int argc, char **argv) { int i; - DIR *dirp; char path[MAXPATHLEN]; nvlist_t *ret = NULL, *config; int fd; @@ -824,7 +823,6 @@ free(ne); } - return (ret); } ==== //depot/projects/trustedbsd/audit3/contrib/top/top.c#6 (text+ko) ==== @@ -13,7 +13,7 @@ * Copyright (c) 1994, 1995, William LeFebvre, Argonne National Laboratory * Copyright (c) 1996, William LeFebvre, Group sys Consulting * - * $FreeBSD: src/contrib/top/top.c,v 1.21 2007/04/17 03:12:39 rafan Exp $ + * $FreeBSD: src/contrib/top/top.c,v 1.22 2007/04/19 14:24:54 rafan Exp $ */ /* @@ -410,7 +410,7 @@ default: fprintf(stderr, "Top version %s\n" -"Usage: %s [-bCHIinqStuv] [-d count] [-m io | cpu] [-o field] [-s time]\n" +"Usage: %s [-abCHIijnqStuv] [-d count] [-m io | cpu] [-o field] [-s time]\n" " [-U username] [number]\n", version_string(), myname); exit(1); ==== //depot/projects/trustedbsd/audit3/etc/rc.d/zfs#3 (text+ko) ==== @@ -1,11 +1,10 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/zfs,v 1.4 2007/04/15 18:07:14 pjd Exp $ +# $FreeBSD: src/etc/rc.d/zfs,v 1.5 2007/04/22 20:55:08 pjd Exp $ # # PROVIDE: zfs # REQUIRE: mountcritlocal -# KEYWORD: nojail . /etc/rc.subr @@ -15,7 +14,14 @@ stop_cmd="zfs_stop" required_modules="zfs" -zfs_start() +zfs_start_jail() +{ + if [ `$SYSCTL_N security.jail.mount_allowed` -eq 1 ]; then + zfs mount -a + fi +} + +zfs_start_main() { zfs volinit zfs mount -a @@ -34,7 +40,23 @@ done } -zfs_stop() +zfs_start() +{ + if [ `$SYSCTL_N security.jail.jailed` -eq 1 ]; then + zfs_start_jail + else + zfs_start_main + fi +} + +zfs_stop_jail() +{ + if [ `$SYSCTL_N security.jail.mount_allowed` -eq 1 ]; then + zfs unmount -a + fi +} + +zfs_stop_main() { # Disable swap on ZVOLs with property org.freebsd:swap=on. zfs list -H -o org.freebsd:swap,name -t volume | \ @@ -50,5 +72,14 @@ zfs volfini } +zfs_stop() +{ + if [ `$SYSCTL_N security.jail.jailed` -eq 1 ]; then + zfs_stop_jail + else + zfs_stop_main + fi +} + load_rc_config $name run_rc_command "$1" ==== //depot/projects/trustedbsd/audit3/lib/libarchive/archive_write_disk_set_standard_lookup.c#2 (text+ko) ==== @@ -24,7 +24,7 @@ */ #include "archive_platform.h" -__FBSDID("$FreeBSD: src/lib/libarchive/archive_write_disk_set_standard_lookup.c,v 1.1 2007/03/03 07:37:36 kientzle Exp $"); +__FBSDID("$FreeBSD: src/lib/libarchive/archive_write_disk_set_standard_lookup.c,v 1.2 2007/04/20 15:32:13 kientzle Exp $"); #ifdef HAVE_SYS_TYPES_H #include <sys/types.h> @@ -72,6 +72,7 @@ id_t id; }; +static const size_t cache_size = 127; static unsigned int hash(const char *); static gid_t lookup_gid(void *, const char *uname, gid_t); static uid_t lookup_uid(void *, const char *uname, uid_t); @@ -99,10 +100,10 @@ int archive_write_disk_set_standard_lookup(struct archive *a) { - struct bucket *ucache = malloc(sizeof(struct bucket[127])); - struct bucket *gcache = malloc(sizeof(struct bucket[127])); - memset(ucache, 0, sizeof(struct bucket[127])); - memset(gcache, 0, sizeof(struct bucket[127])); + struct bucket *ucache = malloc(sizeof(struct bucket[cache_size])); + struct bucket *gcache = malloc(sizeof(struct bucket[cache_size])); + memset(ucache, 0, sizeof(struct bucket[cache_size])); + memset(gcache, 0, sizeof(struct bucket[cache_size])); archive_write_disk_set_group_lookup(a, gcache, lookup_gid, cleanup); archive_write_disk_set_user_lookup(a, ucache, lookup_uid, cleanup); return (ARCHIVE_OK); @@ -113,11 +114,8 @@ { int h; struct bucket *b; - int cache_size; struct bucket *gcache = (struct bucket *)private_data; - cache_size = 127; - /* If no gname, just use the gid provided. */ if (gname == NULL || *gname == '\0') return (gid); @@ -153,11 +151,8 @@ { int h; struct bucket *b; - int cache_size; struct bucket *ucache = (struct bucket *)private_data; - cache_size = 127; - /* If no uname, just use the uid provided. */ if (uname == NULL || *uname == '\0') return (uid); @@ -191,7 +186,12 @@ static void cleanup(void *private) { - free(private); + size_t i; + struct bucket *cache = (struct bucket *)private; + + for (i = 0; i < cache_size; i++) + free(cache[i].name); + free(cache); } ==== //depot/projects/trustedbsd/audit3/lib/libc/net/rthdr.c#3 (text+ko) ==== @@ -30,7 +30,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/lib/libc/net/rthdr.c,v 1.8 2005/07/19 18:13:58 ume Exp $"); +__FBSDID("$FreeBSD: src/lib/libc/net/rthdr.c,v 1.9 2007/04/19 15:48:16 mtm Exp $"); #include <sys/param.h> #include <sys/types.h> @@ -292,7 +292,9 @@ { switch (type) { case IPV6_RTHDR_TYPE_0: - return (((segments * 2) + 1) << 3); + if ((segments >= 0) && (segments <= 127)) + return (((segments * 2) + 1) << 3); + /* FALLTHROUGH */ default: return (0); /* type not suppported */ } @@ -309,6 +311,9 @@ /* length validation */ if (bp_len < inet6_rth_space(IPV6_RTHDR_TYPE_0, segments)) return (NULL); + /* segment validation */ + if ((segments < 0) || (segments > 127)) + return (NULL); memset(bp, 0, bp_len); rth0 = (struct ip6_rthdr0 *)rth; @@ -334,6 +339,9 @@ switch (rth->ip6r_type) { case IPV6_RTHDR_TYPE_0: rth0 = (struct ip6_rthdr0 *)rth; + /* Don't exceed the number of stated segments */ + if (rth0->ip6r0_segleft == (rth0->ip6r0_len / 2)) + return (-1); nextaddr = (struct in6_addr *)(rth0 + 1) + rth0->ip6r0_segleft; *nextaddr = *addr; rth0->ip6r0_segleft++; ==== //depot/projects/trustedbsd/audit3/lib/libc/stdio/fputs.3#4 (text+ko) ==== @@ -30,7 +30,7 @@ .\" SUCH DAMAGE. .\" .\" @(#)fputs.3 8.1 (Berkeley) 6/4/93 -.\" $FreeBSD: src/lib/libc/stdio/fputs.3,v 1.13 2007/04/19 09:38:31 phk Exp $ +.\" $FreeBSD: src/lib/libc/stdio/fputs.3,v 1.14 2007/04/19 14:01:04 phk Exp $ .\" .Dd June 4, 1993 .Dt FPUTS 3 @@ -70,7 +70,7 @@ .Fn fputs and .Fn puts -returns a nonnegative integer on success and +return a nonnegative integer on success and .Dv EOF on error. .Sh ERRORS ==== //depot/projects/trustedbsd/audit3/lib/libfetch/fetch.3#5 (text+ko) ==== @@ -23,9 +23,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/lib/libfetch/fetch.3,v 1.61 2005/11/30 04:08:45 tmclaugh Exp $ +.\" $FreeBSD: src/lib/libfetch/fetch.3,v 1.62 2007/04/22 22:33:29 njl Exp $ .\" -.Dd July 1, 1998 +.Dd April 22, 2007 .Dt FETCH 3 .Os .Sh NAME @@ -334,6 +334,16 @@ .Nm fetch library will attempt an anonymous login, with user name "anonymous" and password "anonymous@<hostname>". +.Pp +By default, +.Nm fetch +changes directories one at a time for the best compatibility with a wide +variety of servers. +If it is compiled with the +.Ql FTP_COMBINE_CWDS +flag, it will first try a single change directory command for the entire +path and fall back to the default scheme if an error occurred. +This can save latency when used with a slow network link. .Sh HTTP SCHEME The .Fn fetchXGetHTTP , ==== //depot/projects/trustedbsd/audit3/lib/libfetch/ftp.c#6 (text+ko) ==== @@ -27,7 +27,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/lib/libfetch/ftp.c,v 1.95 2006/06/13 10:21:03 des Exp $"); +__FBSDID("$FreeBSD: src/lib/libfetch/ftp.c,v 1.96 2007/04/22 22:33:29 njl Exp $"); /* * Portions of this code were taken from or based on ftpio.c: @@ -267,6 +267,7 @@ char pwd[PATH_MAX]; int e, i, len; + /* If no slashes in name, no need to change dirs. */ if ((end = strrchr(file, '/')) == NULL) return (0); if ((e = _ftp_cmd(conn, "PWD")) != FTP_WORKING_DIRECTORY || @@ -276,7 +277,8 @@ } for (;;) { len = strlen(pwd); - /* look for a common prefix */ + + /* Look for a common prefix between PWD and dir to fetch. */ for (i = 0; i <= len && i <= end - file; ++i) if (pwd[i] != file[i]) break; @@ -284,6 +286,7 @@ DEBUG(fprintf(stderr, "have: [%.*s|%s]\n", i, pwd, pwd + i)); DEBUG(fprintf(stderr, "want: [%.*s|%s]\n", i, file, file + i)); #endif + /* Keep going up a dir until we have a matching prefix. */ if (pwd[i] == '\0' && (file[i - 1] == '/' || file[i] == '/')) break; if ((e = _ftp_cmd(conn, "CDUP")) != FTP_FILE_ACTION_OK || @@ -293,6 +296,23 @@ return (-1); } } + +#ifdef FTP_COMBINE_CWDS + /* Skip leading slashes, even "////". */ + for (beg = file + i; beg < end && *beg == '/'; ++beg, ++i) + /* nothing */ ; + + /* If there is no trailing dir, we're already there. */ + if (beg >= end) + return (0); + + /* Change to the directory all in one chunk (e.g., foo/bar/baz). */ + e = _ftp_cmd(conn, "CWD %.*s", (int)(end - beg), beg); + if (e == FTP_FILE_ACTION_OK) + return (0); +#endif /* FTP_COMBINE_CWDS */ + + /* That didn't work so go back to legacy behavior (multiple CWDs). */ for (beg = file + i; beg < end; beg = file + i + 1) { while (*beg == '/') ++beg, ++i; @@ -966,6 +986,8 @@ if ((e = _ftp_authenticate(conn, url, purl)) != FTP_LOGGED_IN) goto fouch; + /* TODO: Request extended features supported, if any (RFC 3659). */ + /* done */ return (conn); ==== //depot/projects/trustedbsd/audit3/lib/libpthread/thread/thr_info.c#4 (text+ko) ==== @@ -26,7 +26,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/lib/libpthread/thread/thr_info.c,v 1.29 2007/01/12 07:26:18 imp Exp $ + * $FreeBSD: src/lib/libpthread/thread/thr_info.c,v 1.30 2007/04/23 03:36:14 deischen Exp $ */ #include <stdio.h> #include <stdlib.h> @@ -214,12 +214,31 @@ void _pthread_set_name_np(pthread_t thread, char *name) { - /* Check if the caller has specified a valid thread: */ - if (thread != NULL && thread->magic == THR_MAGIC) { - if (thread->name != NULL) { + struct pthread *curthread = _get_curthread(); + char *new_name; + char *prev_name; + int ret; + + new_name = strdup(name); + /* Add a reference to the target thread. */ + if (_thr_ref_add(curthread, thread, 0) != 0) { + free(new_name); + ret = ESRCH; + } + else { + THR_THREAD_LOCK(curthread, thread); + prev_name = thread->name; + thread->name = new_name; + THR_THREAD_UNLOCK(curthread, thread); + _thr_ref_delete(curthread, thread); + if (prev_name != NULL) { /* Free space for previous name. */ - free(thread->name); + free(prev_name); } - thread->name = strdup(name); + ret = 0; } +#if 0 + /* XXX - Should return error code. */ + return (ret); +#endif } ==== //depot/projects/trustedbsd/audit3/libexec/ftpd/ftpd.8#7 (text+ko) ==== @@ -30,9 +30,9 @@ .\" SUCH DAMAGE. .\" .\" @(#)ftpd.8 8.2 (Berkeley) 4/19/94 -.\" $FreeBSD: src/libexec/ftpd/ftpd.8,v 1.72 2007/04/18 22:43:39 yar Exp $ +.\" $FreeBSD: src/libexec/ftpd/ftpd.8,v 1.74 2007/04/20 09:08:20 trhodes Exp $ .\" -.Dd January 21, 2006 +.Dd April 20, 2007 .Dt FTPD 8 .Os .Sh NAME @@ -79,20 +79,19 @@ .Dv AF_INET6 socket. .It Fl 8 -The server is running in transparent UTF-8 mode. -That is, it just encourages RFC\ 2640 compliant clients to send -paths encoded in UTF-8 in their commands. -In particular, the names of files uploaded by such clients will -have UTF-8 encoding. -The clients will also assume that server replies and existing file -names have UTF-8 encoding, too. -The names of files preloaded to the server should meet this expectation -for the clients to present the correct file names to their users. -Own messages of +Enable transparent UTF-8 mode. +RFC\ 2640 compliant clients will be told that the character encoding +used by the server is UTF-8, which is the only effect of the option. +.Pp +This option does not enable any encoding conversion for server file names; +it implies instead that the names of files on the server are encoded +in UTF-8. +As for files uploaded via FTP, it is the duty of the RFC\ 2640 compliant +client to convert their names from the client's local encoding to UTF-8. +FTP command names and own .Nm -are always encoded in ASCII, which in fact is a subset of UTF-8. -.Pp -Note that this option does not make the server do any encoding conversion. +messages are always encoded in ASCII, which is a subset of UTF-8. +Hence no need for server-side conversion at all. .It Fl A Allow only anonymous ftp access. .It Fl a @@ -356,16 +355,15 @@ and not have a null password. In this case a password must be provided by the client before any file operations may be performed. -If the user has an S/Key key, the response from a successful USER -command will include an S/Key challenge. +If the user has an OPIE key, the response from a successful USER +command will include an OPIE challenge. The client may choose to respond with a PASS command giving either -a standard password or an S/Key one-time password. +a standard password or an OPIE one-time password. The server will automatically determine which type of password it has been given and attempt to authenticate accordingly. See -.Xr key 1 -for more information on S/Key authentication. -S/Key is a Trademark of Bellcore. +.Xr opie 4 +for more information on OPIE authentication. .It The login name must not appear in the file .Pa /etc/ftpusers . @@ -559,9 +557,9 @@ .El .Sh SEE ALSO .Xr ftp 1 , -.Xr key 1 , .Xr umask 2 , .Xr getusershell 3 , +.Xr opie 4 , .Xr ftpchroot 5 , .Xr login.conf 5 , .Xr inetd 8 , ==== //depot/projects/trustedbsd/audit3/release/doc/en_US.ISO8859-1/relnotes/article.sgml#5 (text+ko) ==== @@ -30,7 +30,7 @@ <corpauthor>The &os; Project</corpauthor> - <pubdate>$FreeBSD: src/release/doc/en_US.ISO8859-1/relnotes/article.sgml,v 1.1018 2007/04/17 07:01:45 brueffer Exp $</pubdate> + <pubdate>$FreeBSD: src/release/doc/en_US.ISO8859-1/relnotes/article.sgml,v 1.1021 2007/04/21 03:45:18 hrs Exp $</pubdate> <copyright> <year>2000</year> @@ -438,14 +438,19 @@ statistics via a binary structure stream.</para> <para>The sysctl variable <varname>hw.pci.do_powerstate</varname> - has been changed from a boolean to a range. + has been split into two sysctl variables + <varname>hw.pci.do_powerstate_nodriver</varname> + and <varname>hw.pci.do_powerstate_resume</varname>. + Also, these variables have been changed from a boolean to a range. <literal>0</literal> means no power management, <literal>1</literal> means conservative power management which any device class that has caused problems is added to the watch list, <literal>2</literal> means aggressive power management where any device class that is not fundamental to the system is added to the list, and <literal>3</literal> means power them all down unconditionally. - The default is <literal>1</literal>.</para> + The default values are <literal>0</literal> for + <varname>hw.pci.do_powerstate_nodriver</varname> and + <literal>1</literal> for <varname>hw.pci.do_powerstate_resume</varname>.</para> <para>[&arch.ia64;] The <filename>GENERIC</filename> kernel now enables SMP support by default.</para> @@ -499,6 +504,9 @@ <para>[&arch.pc98;] A bootable CDROM loader has been implemented for the pc98 platform. &merged;</para> + <para>[&arch.pc98;] The <application>IPLware</application> support + in boot0.5 has been enhanced to support version 3.33.</para> + <para>[&arch.i386;] A bug in the i386 boot loader, which could cause file system corruption if a <filename>nextboot.conf</filename> file was used and landed @@ -978,6 +986,10 @@ IPv6 support, it should be used instead. Please note that some rules might need to be adjusted.</para> + <para>The &man.lagg.4; driver, ported from OpenBSD and NetBSD, + has been added to support a variety of protocols and algorithms + for link aggregation, failover, and fault tolerance.</para> + <para>The &man.natm.4;, Native Mode ATM protocol layer is now MPSAFE.</para> <para>A new &man.ng.deflate.4; Netgraph node type has been @@ -1103,10 +1115,6 @@ devices will marked <literal>up</literal> upon creation. &merged; </para> - <para>The &man.lagg.4; driver, ported from OpenBSD and NetBSD, - has been added to support a variety of protocols and algorithms - for link aggregation, failover, and fault tolerance.</para> - <para>Support for &man.kqueue.2; operations has been added to the &man.tun.4; driver. &merged;</para> @@ -1133,6 +1141,10 @@ <para>The &man.arcmsr.4; driver has been updated to version 1.20.00.13. &merged;</para> + <para>The &man.ahc.4; driver is now MPSAFE.</para> + + <para>The &man.ahd.4; driver is now MPSAFE.</para> + <para>The &man.ata.4; driver now supports a workaround for some controllers whose DMA does not work properly in 48bit mode. For affected controllers, @@ -1158,6 +1170,8 @@ <para>The &man.ataraid.4; driver now supports JMicron ATA RAID metadata. &merged;</para> >>> TRUNCATED FOR MAIL (1000 lines) <<<
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200704231444.l3NEibbh061754>