summaryrefslogtreecommitdiffstats
path: root/usr.sbin
Commit message (Collapse)AuthorAgeFilesLines
* Fix alignment related warnings reported by gcceadler2012-10-022-29/+17
| | | | | | | | | | Switch from old style arguments to modern C remove WARNS as a result tested with "make universe" Approved by: cperciva MFC after: 1 week
* mdoc: point to an existing cross reference.pluknet2012-10-021-1/+1
|
* Fix build with LOG_FILE undefined and DEBUGGING disabled.pluknet2012-10-021-0/+2
|
* Fix build with DEBUGGING disabled.pluknet2012-10-021-0/+4
|
* Do not treat empty name as an uid 0bapt2012-10-011-1/+2
| | | | Reported by: Robert Bonomi <bonomi@mail.r-bonomi.com>
* Remove useless atoi(3), previous strspn(3) makes sure that a_name->val is abapt2012-10-011-2/+1
| | | | | | | | | number. This also allow pw user show to work as expected. PR: bin/172112 Submitted by: "Ilya A. Arkhipov" <rum1cro@yandex.ru> MFC after: 1 month
* Document the security.bsd.unprivileged_idprio in idprio(1) in additioneadler2012-09-301-1/+9
| | | | | | | to rtprio(2). Approved by: wblock MFC after: 3 days
* Allow deferred word-splitting via f_sysrc_get() by allowing $IFS in thedteske2012-09-291-3/+2
| | | | | | | | | | | | | | "clean-room" environment used to query rc.conf(5) parameters. This brings bsdconfig(8)'s sysrc.subr in-line with both the sysrc(8) manual [provided by sysutils/sysrc] and sysrc(8)'s own sysrc.subr (now identical to bsdconfig(8)'s sysrc.subr as of this patch). Finally, this will allow a clean import of sysutils/sysrc (sans sysrc.subr, already provided here). Reviewed by: jilles Approved by: adrian (co-mentor)
* Change "only only" to "only" in portsnap(8).issyl02012-09-281-1/+1
| | | | | Spotted by: Ruslan Mahmatkhanov Approved by: gabor (mentor, implicit)
* Add a note to portsnap(8) about the behaviour of the example cron command.issyl02012-09-281-1/+18
| | | | | | | PR: docs/171759 Submitted by: Paul Hoffman (phoffman at proper dot com) Approved by: cperciva, gabor (mentor) MFC after: 3 days
* Make sure that each va_start has one and only one matching va_end,kevlo2012-09-282-0/+2
| | | | especially in error cases.
* Sanitize varname argument in f_sysrc_find. This is as much for security as itdteske2012-09-281-2/+15
| | | | | | | is for sanity. Reviewed by: jilles Approved by: adrian (co-mentor)
* Fix usr.bin/ and usr.sbin/ build with a 64-bit ino_t.mdf2012-09-274-8/+11
| | | | Original code by: Gleb Kurtsou
* Attila Bogar reported a bug in mountd when multiple exportrmacklem2012-09-241-14/+57
| | | | | | | | | | | | | | | | entries with different security flavors are in the exports(5) file. For that case, mountd replies with the security flavors of the last entry and not the correct one for the client host. This patch fixes that by storing separate copies of the flavors for each host/net case, plus a default one for the case where no hosts/nets are specified on an entry in the exports(5) file. Unlike the patch in the PR, it replies with the security flavors for the entry instead of merging the security flavors for all the entries and replying with that. Tested by: attila.bogar at linguamatics.com PR: kern/164933 MFC after: 2 weeks
* Make sure moused is exiting as quick as possible after that thehselasky2012-09-241-12/+8
| | | | | | | | | | | | | | | umsX character device returns a read error. Update devd.conf rules to use "DEVFS" events which are generated after that the umsX character device node has been created/destroyed, and then there should be no need for moused to wait up to 10 seconds for umsX to be ready. Opening umsX should not fail except if the kernel is low on memory. In that case the user can replug the USB mouse or use "usbconfig" to reset the device. In case of USB mouse devices, moused should neither retry to open its character device, once the first read error has happened. This is an indication of device detach. MFC after: 1 week
* Always use RC_CONFS when set, even if NULL. Previously only used if non-NULL.dteske2012-09-231-3/+3
| | | | | Reviewed by: jilles, adrian (co-mentor) Approved by: adrian (co-mentor)
* jilles accurately advises that, in the context of shell redirection, the `:'dteske2012-09-221-1/+1
| | | | | | | | | | | | | | | | | | builtin is processed specially and thus the `: > file' syntax for example will cause premature termination of the current shell on redirection-error. The `true' builtin on the other-hand is not included in this special processing (for compatibility reasons to satisfy legacy scripts programmed for systems where `true' is not a builtin). Change bare `: > file' syntax into `true > file' syntax to prevent premature shell termination in the event of redirection-error. NOTE: Instances of `: > file' that appear within a sub-shell have been left unmodified as these will not cause premature termination of the main script. Reviewed by: jilles, adrian (co-mentor) Approved by: adrian (co-mentor)
* Replace "( : ${var?} )" syntax with better "[ ${var+set} ]" syntax.dteske2012-09-225-11/+7
| | | | | Reviewed by: jilles, adrian (co-mentor) Approved by: jilles, adrian (co-mentor)
* Spelling and whitespace corrections.dteske2012-09-224-8/+8
| | | | | Reviewed by: adrian (co-mentor) Approved by: adrian (co-mentor)
* Reverse SVN r240770 -- jilles@ made a suggestion that allowed us to redesigndteske2012-09-2122-62/+62
| | | | | | | our embedded rescue environment to support /dev/null making r240770 obsolete. Reviewed by: jilles, adrian (co-mentor) Approved by: jilles, adrian (co-mentor)
* Replace redirections to /dev/null with "close file-descriptor" syntax (>&-).dteske2012-09-2122-62/+62
| | | | | Reviewed by: adrian (co-mentor) Approved by: adrian (co-mentor)
* Change all invocations of dialog(1) to no-longer require temporary files.dteske2012-09-2039-188/+441
| | | | | | | This allows bsdconfig to -- like bsdinstall -- operate from read-only media. Reviewed by: adrian (co-mentor) Approved by: adrian (co-mentor)
* The correct generic term for PCIS_STORAGE_NVM is "NVM" not "NVM Express".gavin2012-09-201-1/+1
| | | | | Submitted by: jimharris MFC after: 6 days
* Recognise NVM Express devices and pretty-print their name.gavin2012-09-191-0/+1
| | | | MFC after: 1 week
* Move major includes into /usr/share/bsdconfig for easy external access.dteske2012-09-1885-381/+455
| | | | | Reviewed by: adrian (co-mentor) Approved by: adrian (co-mentor)
* if a file in plist starts with / then do not prefix it with "prefix" [1]bapt2012-09-188-30/+67
| | | | | | | | | | | | | | | | | | | | | | | | pkg info -g returns 1 if a file mismatch [2] flush stdout in pkg info -g [3] clean up quiet mode (-q | --quiet) output of pkg_version(1) [4] fix missing error call in uname check added to pkg_version(1) [5] fix pkg_add(1) fails to install with -C from bad path [6] only resolve path from pkg_add(1) -p if the given prefix do not start with a '/' [7] PR: bin/13128 [1] bin/139015 [2] bin/113702 [3] bin/142570 [4] bin/146857 [5] bin/157543 [6] Submitted by: cy [1] Anton Yuzhaninov <citrin@citrin.ru> [2] Ighighi <ighighi@gmail.com> [3] "N.J. Mann" <njm@njm.me.uk> [4] gcooper [5] David Naylor <naylor.b.david@gmail.com> [6] netchild [7] MFC after: 2 weeks
* Align the PCI Express #defines with the style used for the PCI-Xgavin2012-09-182-34/+34
| | | | | | | | | | | | | | | | | #defines. This also has the advantage that it makes the names more compact, iand also allows us to correct the non-uniform naming of the PCIM_LINK_* defines, making them all consistent amongst themselves. This is a mostly mechanical rename: s/PCIR_EXPRESS_/PCIER_/g s/PCIM_EXP_/PCIEM_/g s/PCIM_LINK_/PCIEM_LINK_/g When this is MFC'd, #defines will be added for the old names to assist out-of-tree drivers. Discussed with: jhb MFC after: 1 week
* In snmp_hostres, device_map table is used for consistent device tabletrociny2012-09-171-0/+6
| | | | | | | | | | | | | | | | | | | | | indexing. When a device has gone it is not removed from device_map table but just its entry_p field is set to NULL. So when traversing device_map in disk_OS_get_ATA_disks() and disk_OS_get_MD_disks() check for entry_p being NULL, otherwise the bsnmpd crash is possible when a removed map entry is dereferenced. Before the fix, for disk_OS_get_ATA_disks() the crash could be easily reproduced running: atacontrol detach ata1 The crash was not observed in disk_OS_get_MD_disks() because currently snmp_hostres does no see md(4) disks: to get the device list it uses devinfo(3), which does not return md devices. Reported by: Miroslav Lachman 000.fbsd quip.cz MFC after: 1 week
* Warn about filesystem-based attacks.des2012-09-161-1/+9
|
* Remove a reference to CVS and to freefall from a user-facing man page.issyl02012-09-151-4/+3
| | | | | | | PR: docs/171658 Reported by: Chris Petrik (c dot petrik dot sosa at gmail dot com) Approved by: gabor (mentor) MFC after: 5 days
* Correct double "the the"eadler2012-09-142-3/+3
| | | | | Approved by: cperciva MFC after: 3 days
* Bump date missed in r202756eadler2012-09-142-2/+2
| | | | | | | PR: docs/171624 Submitted by: bdrewery Approved by: gabor MFC after: 3 days
* o Create directory sys/netpfil, where all packet filters shouldglebius2012-09-142-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | reside, and move there ipfw(4) and pf(4). o Move most modified parts of pf out of contrib. Actual movements: sys/contrib/pf/net/*.c -> sys/netpfil/pf/ sys/contrib/pf/net/*.h -> sys/net/ contrib/pf/pfctl/*.c -> sbin/pfctl contrib/pf/pfctl/*.h -> sbin/pfctl contrib/pf/pfctl/pfctl.8 -> sbin/pfctl contrib/pf/pfctl/*.4 -> share/man/man4 contrib/pf/pfctl/*.5 -> share/man/man5 sys/netinet/ipfw -> sys/netpfil/ipfw The arguable movement is pf/net/*.h -> sys/net. There are future plans to refactor pf includes, so I decided not to break things twice. Not modified bits of pf left in contrib: authpf, ftp-proxy, tftp-proxy, pflogd. The ipfw(4) movement is planned to be merged to stable/9, to make head and stable match. Discussed with: bz, luigi
* Do not change owner, group, or mode when package database directory andjkim2012-09-145-6/+7
| | | | | | | | its contents are created with pkg_add(1). It may happen when the packing list contains @owner, @group, or @mode. Reported by: Donald Bostrom (dbostrom at niksun dot com) Reviewed by: portmgr (bapt)
* - Denote PCI-e endpoints that support FLR.jhb2012-09-132-4/+72
| | | | | | | | | - Make parsing of PCI-e extended capabilities assume that future version numbers are backwards compatible. - Add new AER error descriptions. - Add descriptions for more PCI-e extended capabilities. MFC after: 1 week
* Add documentation for IPv6 supporteadler2012-09-121-1/+9
| | | | | | | | | PR: docs/171580 Submitted by: bdrewery Reviewed by: wblock Approved by: gjb MFC after: 1 month X-MFC-With: r240389
* Add support for ipv6 addresses as destinationbapt2012-09-121-1/+12
| | | | | | | PR: bin/150530 Submitted by: andy white <andywhite@gmail.com> Tested by: Olivier Cochard-Labbe <olivier@cochard.me> MFC after: 1 month
* Add missing braceskevlo2012-09-121-1/+2
| | | | Obtained from: DragonFly
* Do not count kernel threads as processes for hrSystemProcesses OID.glebius2012-09-111-1/+1
| | | | | PR: bin/160494 Submitted by: Jeremy Chadwick <freebsd jdc.parodius.com>
* Spelling.glebius2012-09-111-1/+1
|
* Remove unused valueskevlo2012-09-111-1/+1
|
* Remove dead return codekevlo2012-09-111-2/+0
|
* mdoc fixes.joel2012-09-081-41/+21
|
* Merge the projects/pf/head branch, that was worked on for last six months,glebius2012-09-083-6/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into head. The most significant achievements in the new code: o Fine grained locking, thus much better performance. o Fixes to many problems in pf, that were specific to FreeBSD port. New code doesn't have that many ifdefs and much less OpenBSDisms, thus is more attractive to our developers. Those interested in details, can browse through SVN log of the projects/pf/head branch. And for reference, here is exact list of revisions merged: r232043, r232044, r232062, r232148, r232149, r232150, r232298, r232330, r232332, r232340, r232386, r232390, r232391, r232605, r232655, r232656, r232661, r232662, r232663, r232664, r232673, r232691, r233309, r233782, r233829, r233830, r233834, r233835, r233836, r233865, r233866, r233868, r233873, r234056, r234096, r234100, r234108, r234175, r234187, r234223, r234271, r234272, r234282, r234307, r234309, r234382, r234384, r234456, r234486, r234606, r234640, r234641, r234642, r234644, r234651, r235505, r235506, r235535, r235605, r235606, r235826, r235991, r235993, r236168, r236173, r236179, r236180, r236181, r236186, r236223, r236227, r236230, r236252, r236254, r236298, r236299, r236300, r236301, r236397, r236398, r236399, r236499, r236512, r236513, r236525, r236526, r236545, r236548, r236553, r236554, r236556, r236557, r236561, r236570, r236630, r236672, r236673, r236679, r236706, r236710, r236718, r237154, r237155, r237169, r237314, r237363, r237364, r237368, r237369, r237376, r237440, r237442, r237751, r237783, r237784, r237785, r237788, r237791, r238421, r238522, r238523, r238524, r238525, r239173, r239186, r239644, r239652, r239661, r239773, r240125, r240130, r240131, r240136, r240186, r240196, r240212. I'd like to thank people who participated in early testing: Tested by: Florian Smeets <flo freebsd.org> Tested by: Chekaluk Vitaly <artemrts ukr.net> Tested by: Ben Wilber <ben desync.com> Tested by: Ian FREISLICH <ianf cloudseed.co.za>
* Add TRIM support, enabled by default.jpaetzel2012-09-066-21/+88
| | | | | | | | | | Fix a bug installing components from a localPath. Allow autosizing of any partition, not just the last partition. Adjust how ZFS is laid out to work with Boot Environments. Submitted by: kmoore Obtained from: PC-BSD MFC after: 3 days
* - If the PCIe "SLOT" flag is set, include this in the capability outputgavin2012-09-051-1/+3
| | | | | | - Fix printing of PCIe interrupt number, the shift was incorrect. MFC after: 1 week
* Provide a sysctl switch that allows to install ARP entriesglebius2012-09-031-0/+11
| | | | | | | | with multicast bit set. FreeBSD refuses to install such entries since 9.0, and this broke installations running Microsoft NLB, which are violating standards. Tested by: Tarasov Oleg <oleg_tarasov sg-tea.com>
* Explicitly document all variables in the net.link.ether.inet MIB.glebius2012-09-031-5/+38
|
* Rework all non-contributed files that use `struct timezone'.ed2012-09-019-52/+43
| | | | | | | | | | | | | | This structure is not part of POSIX. According to POSIX, gettimeofday() has the following prototype: int gettimeofday(struct timeval *restrict tp, void *restrict tzp); Also, POSIX states that gettimeofday() shall return 0 (as long as tzp is not used). Remove dead error handling code. Also use NULL for a nul-pointer instead of integer 0. While there, change all pieces of code that only use tv_sec to use time(3), as this provides less overhead.
* Rework time handling.ed2012-09-011-8/+7
| | | | | | | | | After I made the previous commit, I noticed the code does some things it shouldn't. It casts a struct timeval to a time_t, assuming tv_sec is the first member. Also, we are not interested in microseconds, so it is better to just call time(NULL). MFC after: 1 month
OpenPOWER on IntegriCloud