14901 Commits

Author SHA1 Message Date
mav
048cd8404d MFC r287766: Add negotiation of iSCSIProtocolLevel to 2 (RFC7144).
We may need to pass negotiated value to kernel level, but so far it is
not necessary, since it does not use any new features without request.
2015-10-05 09:16:01 +00:00
mav
a0bb28fd76 MFC r287757: When updating port, apply only change of LUN map, not whole. 2015-10-05 09:11:46 +00:00
mav
2ae17b4970 MFC r287707: CTL documentation update, mostly for HA. 2015-10-05 09:01:19 +00:00
mav
63b0da2b15 MFC r287620: Remove unused target and initiator IDs. 2015-10-05 08:55:59 +00:00
mav
f1a03e38c5 MFC r287534: Add two new portal group options "tag" and "foreign".
They are going to be useful in clustered setups.
2015-10-05 08:54:02 +00:00
mav
3f61db5756 MFC r287500: Allow LUN options modification via CTL_LUNREQ_MODIFY.
Not all changes take effect, but that is a different question.
2015-10-05 08:52:37 +00:00
mav
158f0406b0 MFC r287455, r287458, r287459: Remove some dead code. 2015-10-05 08:50:15 +00:00
mav
656a5c3136 MFC r286806: Drop "internal" CTL frontend.
Its idea was to be a simple initiator and execute several commands from
kernel level, but FreeBSD never had consumer for that functionality,
while its implementation polluted many unrelated places.
2015-10-05 08:42:43 +00:00
bapt
49c462994f MFC 287473,287485,287493,287494
Add a new sesutil(8) utility

This is an utility for managing SCSI Enclosure Services (SES) device.

For now only one command is supported "locate" which will change the test of the
external LED associated to a given disk.

Usage if the following:
sesutil locate disk [on|off]

Disk can be a device name: "da12" or a special keyword: "all".

Reviewed by:	mav
Relnotes:	yes
Sponsored by:	gandi.net
2015-10-05 08:18:31 +00:00
mav
64e021919b MFC r281532 (by delphij): Eliminate unused headers. 2015-10-05 07:42:05 +00:00
mav
f3e1fd582e MFC r279314 (by trasz): Add missing error check. 2015-10-05 07:33:54 +00:00
mav
f7a8b2b7ad MFC r278622 (by trasz): Remove unused code. 2015-10-05 07:31:51 +00:00
bdrewery
3439b1010e MFC r287982:
Replace afterinstall: hack from r54681 with 'make delete-old' functionality.
2015-10-03 16:26:13 +00:00
delphij
12a956c8b5 Fix a regression with SA-15:24 patch that prevented NIS from
working.
2015-10-02 16:36:16 +00:00
bdrewery
72912c00d1 MFC r288381:
All supported releases have the -m support from r186678, so remove the
  mention of it and reword this a bit to remove 'you'.
2015-10-02 16:22:21 +00:00
bdrewery
3a03397095 MFC r288380:
Document the post-merge actions of calling tzsetup(8) and services_mkdb(8)
  added in r259134.
2015-10-02 16:21:14 +00:00
vangyzen
2101014bc0 MFC r280793
pmcstat.8: fix -a flag description; improve -m flag to match

The -a flag reads a file saved by -O, not -o.

The -m flag requires the -R flag.  Copy that paragraph from -a.

Sponsored by:	Dell Inc.
2015-10-02 14:11:44 +00:00
delphij
702cf0edc4 MFC r287927:
Use strlcpy() instead of strncpy() because subsequent mkstemps expects
the string be nul-terminated.

Reviewed by:	neel
2015-10-01 00:44:45 +00:00
bdrewery
34455869c0 MFC r287979:
Remove redundant beforeinstall.
2015-09-29 21:47:50 +00:00
jhb
7b63f549f4 MFC 283613,287374:
Use the cpuset API more consistently:
- Fetch the root set from cpuset_getaffinity() instead of assuming all CPUs
  from 0 to hw.ncpu are the root set.
- Use CPU_SETSIZE and CPU_FFS.
- The original notion of halted CPUs the manpage and code refers to is gone.
  Use the term "available" instead.
2015-09-29 18:39:58 +00:00
delphij
cfb7569733 The Sun RPC framework uses a netbuf structure to represent the
transport specific form of a universal transport address.  The
structure is expected to be opaque to consumers.  In the current
implementation, the structure contains a pointer to a buffer
that holds the actual address.

In rpcbind(8), netbuf structures are copied directly, which would
result in two netbuf structures that reference to one shared
address buffer.  When one of the two netbuf structures is freed,
access to the other netbuf structure would result in an undefined
result that may crash the rpcbind(8) daemon.

Fix this by making a copy of the buffer that is going to be freed
instead of doing a shallow copy.

Security:	FreeBSD-SA-15:24.rpcbind
Security:	CVE-2015-7236
2015-09-29 18:06:27 +00:00
jkim
b7d943cea5 MFC: r288116
Remove unsupported S5 (power off) state.
2015-09-25 22:19:35 +00:00
jkim
1ac5c71d8b MFC: r267248, r267260, r267261, r267320
Document 'k' option for acpiconf(8).
2015-09-25 22:08:20 +00:00
jpaetzel
ca4140311b MFC 288208
Fix typo.

Sponsored by:	iXsystems
2015-09-25 03:54:10 +00:00
delphij
abaf4cee12 MFC r287650:
Use strlcpy() in favor of strncpy() as it's defined to have a nul character
at the end of string buffer, and the code context do expects this to behave
correctly (e.g. strchr).
2015-09-25 01:17:24 +00:00
hrs
50371a834c MFC 281734-281736,287997-287998:
- Fix a crash on a rpc entry when an IPv6 address is explicitly
  specified in -a flag.

- Fix a bug that sockaddr_in was used where sockaddr_in6 should have
  been used.  This was not actually harmful because offsetof(struct
  sockaddr_in, sin_port) is equal to offsetof(struct sockaddr_in6,
  sin6_port).

- Remove unused union p_un.

- Use NI_MAXHOST-long buffer for getnameinfo().
  Although INET6_ADDRSTRLEN was designed to hold the longest
  IPv6 address in IPv4-mapped address format a long time ago,
  getnameinfo() can return scope identifier in addition to it.
2015-09-20 22:27:19 +00:00
bapt
7a94803fa4 MFC: r287580
Remove extra debug that crept in
2015-09-15 05:56:16 +00:00
bapt
07bd68bf9d MFC: r287579
Implement pubkey support for the bootstrap

Note that to not interfer with finger print it expects a signature on pkg itself
which is named pkg.txz.pubkeysign

To genrate it:
echo -n "$(sha256 -q pkg.txz)" | openssl dgst -sha256 -sign /thekey \
    -binary -out ./pkg.txz.pubkeysig

Note the "echo -n" which prevent signing the '\n' one would get otherwise

PR:		202622
2015-09-15 05:46:55 +00:00
bapt
95285c2f6d MFC: r287701
Regression: fix pw usermod -d

Mark the user has having been edited if -d option is passed to usermod and
so the request change of home directory actually happen

PR:		203052
Reported by:	lenzi.sergio@gmail.com
2015-09-14 05:37:32 +00:00
bapt
44b5ad6955 MFC: r287522
Prefer pciids database from ports if present

Given the pciids database on ports is updated more often than the one in base
prefer this version if present, otherwise read the one from base.

Relnotes:	yes
Differential Revision:	https://reviews.freebsd.org/D3391
2015-09-13 07:15:45 +00:00
hrs
bb012e622f MFC 259169, 259176, 287097:
- Ansify function definitions.

- Change the type of addr argument in dump() function to be able
  disambiguate link-local addresses from different zones.

- Add static and remove unused variables.
2015-09-13 03:09:21 +00:00
hrs
8de92fe779 MFC 287095, 287610, 287611, 287617:
Remove obsolete API (SIOCGDRLST_IN6 and SIOCGPRLST_IN6) support.
2015-09-13 01:59:50 +00:00
cy
8cb3d8b817 MFC r287468, turn on RAWDCF by default. 2015-09-12 02:36:17 +00:00
sbruno
906861047e MFC r277853
Check for invalid length or more than max length for the interpreter, instead
of the validity of the string pointer holding the interpreter.

Submitted by:	sson
2015-09-04 15:45:42 +00:00
asomers
60980f847d MFC r286964
Add ATF functional tests for fstyp(8).  No ZFS or GELI tests yet.
2015-09-03 19:42:56 +00:00
asomers
2fa34e5809 MFC r286892
Serve /etc/eui64 via NIS.

The C library already knows how to lookup eui64 entries from NIS. For
example, fwcontrol(8) does it. But /var/yp/Makefile.dist doesn't build the
eui64 maps, and ypinit(8) doesn't push them to slaves. This change fixes
that.
2015-09-01 18:57:57 +00:00
brueffer
f7a0594beb MFC: r286409
Manpage cleanup.

- new sentence -> new line
- fix manpage references
- fix macro usage
- fix a typo
2015-08-24 14:32:57 +00:00
bapt
99f1ebbac6 MFC: r285133,r285136,r285137,r285156,r285157,r285158,r285256,r285318,r285395,
r285396,r285398,r285401,r285403,r285405,r285406,r285408,r285409,r285411,
r285412,r285413,r285415,r285418,r285430,r285433,r285434,r285442,r285948,
r285984,r285985,r285989,r285996,r285997,r286045,r286047,r286066,r286150,
r286151,r286152,r286154,r286155,r286156,r286157,r286173,r286196,r286197,
r286198,r286199,r286200,r286201,r286202,r286203,r286204,r286210,r286211,
r286217,r286218,r286258,r286259,r286341,r286775,r286982,r286986,r286991,
r286993

Validate most pw inputs.
Rewrite the way parsing sub arguments is made to simplify code and improve
maintenability
Add -y (NIS) to userdel/usermod
pw userdel -r <rootdir> now deletes directories in the rootdir
Only parse pw.conf when needed
Reject usermod and userdel if the user concerned is not on the user database
supposed to be manipulated
2015-08-23 21:42:27 +00:00
ian
ba6c7e724c MFC r286947: Add a new exit-timeout option to watchdogd. 2015-08-23 20:39:19 +00:00
mav
170343c951 MFC r286462: Refactor early stages of security negotiation. 2015-08-22 16:59:27 +00:00
delphij
99883f69b1 Instant-MFC r286933:
Issue warning and refuse to proceed further if the configured
repository signature_type is unsupported by bootstrap pkg(7).

Previously, when signature_type specified an unsupported method,
the bootstrap pkg(7) would proceed like when signature_type is
"none".  MITM attackers may be able to use this vulnerability and
bypass validation and install their own versions of pkg(8).

At this time, only fingerprint and none are supported by the
bootstrap pkg(7).

FreeBSD's official pkg(8) repository uses the fingerprint method
and is therefore unaffected.

Errata candidate.
2015-08-19 18:32:36 +00:00
mav
69ac9bf2f9 MFC r286456: Remove some code duplication. 2015-08-15 11:08:30 +00:00
mav
700151794a MFC r286621, r286622: Fix couple minor typos. 2015-08-14 04:23:17 +00:00
bapt
c527db206b Fix segfault were modifying the uid of a user
Do a direct commit as the code on head has changed a lot and does not fail in
that case

PR:		202111
Reported by:	gondim@bsdinfo.com.br
2015-08-05 20:32:07 +00:00
emaste
e6c899bb95 MFC r281581: vidcontrol: make size argument optional again for syscons
r273544 (MFC in r273921) changed the -f option allow no arguments in vt
mode (used to reset the font back to the default), but broke the
optionality of the size argument for syscons. Drop the required argument
from syscons' optstring for -f so the optional argument handler works
the same way for both syscons and vt.

Sponsored by:	The FreeBSD Foundation
2015-08-04 15:15:06 +00:00
gjb
1a0e1b3909 MFC r286285:
Ensure the local MANIFEST is always used when verifying remote
 distribution sets.

Approved by:	re (glebius, insta-MFC)
Sponsored by:	The FreeBSD Foundation
2015-08-04 13:41:37 +00:00
dru
d7898664fe MFC r285869.
Fix transposed words in man page.

PR: 201752
Reviewed by: gjb
2015-08-03 16:56:40 +00:00
trasz
a0b545acc6 MFC r282086:
Make setproctitle(3) work in Capsicum capability mode.  This makes
ctld(8) child processes to indicate initiator address and name in
their titles, similar to what iscsid(8) child processes do.

PR:		181352
Sponsored by:	The FreeBSD Foundation
2015-08-03 08:04:31 +00:00
trasz
8c8a81ecdf MFC r284542:
Allow '@' in unquoted strings, such as with the "path" statement.  Note
that one can use any character they like by using double quotes.

PR:		200895
Sponsored by:	The FreeBDS Foundation
2015-08-03 07:28:23 +00:00
trasz
5e028ab6e6 MFC r285086:
Remove OpenSSL dependency from iscsid(8) and ctld(8).

Sponsored by:	The FreeBSD Foundation
2015-08-03 07:20:33 +00:00