Commit Graph

9443 Commits

Author SHA1 Message Date
nathanw
993713df32 Recognize thread objects in addr2sync. 2004-07-06 19:33:53 +00:00
cube
2e61c89539 KERN_CP_TIME returns an arry of uint64_ts, not longs, as noted by Adam
Sampson in PR 23190.  Also, tell about ``kern.cp_time.#CPU''.
2004-07-05 11:45:12 +00:00
mycroft
a10e4d1f3a Cardbus -> CardBus 2004-07-03 17:36:51 +00:00
junyoung
74d67c3551 Add strcasestr(3), case insensitive version of strstr(3).
Bump libc minor.

From FreeBSD.
2004-07-03 08:27:25 +00:00
simonb
b52cdd0dd6 Copy the sparc/sparc64 __longjmp14() way of dealing with signal masks:
* Restore the signal mask with sigprocmask() instead of _UC_SIGMASK,
  * since libpthread may want to interpose on signal handling.

Fixes regress/lib/libpthread/siglongjmp1.
2004-07-03 05:44:55 +00:00
simonb
b4f0be566a Catch up with changes to __fpregset_t.
In __longjmp14(), copy the FP CSR from the correct array and array slot.

Completes fix for PR port-mips/25942.
2004-07-03 05:10:06 +00:00
heas
2cc74cfa3e UDP checksums are always checked (RFC1122 S4.1.3.4), it is not controllable
by net.inet.udp.checksum.
2004-07-02 18:17:45 +00:00
drochner
3e7f9e1481 allocate stack space for temporary storage 2004-07-02 10:17:23 +00:00
christos
4b9f9bad8c remove __UNCONST definition; it is now in <sys/cdefs.h> 2004-07-02 03:00:01 +00:00
sjg
3a0c68edfd Add support for SHA1 hashed passwords.
The algorithm used is essentially PBKDF1 from RFC 2898 but using
hmac_sha1 rather than SHA1 directly (suggested by smb@research.att.com).

 * The format of the encrypted password is:
 * $<tag>$<iterations>$<salt>$<digest>
 *
 * where:
 *      <tag>           is "sha1"
 *      <iterations>    is an unsigned int identifying how many rounds
 *                      have been applied to <digest>.  The number
 *                      should vary slightly for each password to make
 *                      it harder to generate a dictionary of
 *                      pre-computed hashes.  See crypt_sha1_iterations.
 *      <salt>          up to 64 bytes of random data, 8 bytes is
 *                      currently considered more than enough.
 *      <digest>        the hashed password.

hmac.c implementes HMAC as defined in RFC 2104 and includes a unit
test for both hmac_sha1 and hmac_sha1 using a selection of the Known
Answer Tests from RFC 2202.

It is worth noting that to be FIPS compliant the hmac key (password)
should be 10-20 chars.
2004-07-02 00:05:23 +00:00
kleink
d93fc4c14e Tidy up the namespace: lint -> __lint__. 2004-07-01 22:52:34 +00:00
drochner
07be12b505 also provide an alpha assembler implemtation of lrint() 2004-07-01 19:08:21 +00:00
nathanw
3a30736db7 td_sync_info(): explicitly clear the "locked" flag when unlocked,
instead of leaving it as garbage.
2004-07-01 18:59:52 +00:00
nathanw
aaad58dd18 td_map_addr2sync(): recognize read-write lock objects. 2004-07-01 18:27:36 +00:00
drochner
5d151d763f enable lrint.S for amd64 (which doesn't build libm387),
and tighten the generic->machdep source distribution a bit to avoid
unwanted substitutions
2004-07-01 17:33:16 +00:00
drochner
af7cf00a5a provide an assembler implementation of lrint() for i386 and amd64 2004-07-01 17:30:48 +00:00
drochner
9768ef916d bump libm minor version (functions added) 2004-07-01 16:14:18 +00:00
drochner
147d852dbc being here, add the (l)lround(f) functions to libm
(almost the same like lrint)
2004-07-01 16:09:21 +00:00
drochner
54e35f616a aboid to shift an int by more than 31 bits - behaviour is implementation
dependant in this case
2004-07-01 16:06:30 +00:00
kleink
2d356478dd Make the spelling of reentrant match the rest of the system. 2004-07-01 10:38:28 +00:00
skrll
aeb58ad6a0 Add a cerror.S and re-work various syscalls and SYS.h to use __cerror.
With help from the OpenBSD version of SYS.h.
2004-07-01 06:50:04 +00:00
drochner
d45473e8a3 fic the <close-to-1>^<huge number> fix as in e_pow.c 2004-06-30 18:45:25 +00:00
drochner
a6d8e4cf79 -fix a long-standing bug which affects the <close-to-1>^<huge number> case
(fixed in fdlibm-5.3)
-being here, sync with -5.3 as far as possible (There is another bugfix -
 sign in overflow/underflow cases -; this doesn't change anything for us
 because the wrapper (w_pow.c) fixes this up. Keep things in sync anyway
 to ease further maintainance.)
2004-06-30 18:43:15 +00:00
drochner
d76992e490 Implement (l)lrint(f).
(Could get some optimization for LP64; this would need a change to
the float access macros in math_private.h.)
2004-06-30 15:08:30 +00:00
drochner
0e6c93b9fa const'ify the arguments to pthread__assertfunc and _errorfunc;
needed because the __func__ pseudo-var is strictly "const*" in gcc-3.4
2004-06-25 16:33:32 +00:00
drochner
dddd0e25a3 ANSIfy 2004-06-25 15:57:38 +00:00
wiz
a26de71379 Do not xref ourselves; grammar fixes. 2004-06-25 15:29:25 +00:00
wiz
da71bc8372 Sort sections. 2004-06-25 15:27:39 +00:00
itojun
7a97c46b28 support format for if_pflog.c (new format only/old format not supported)
Peter Postma
2004-06-25 12:22:23 +00:00
nathanw
47513cedb9 If the sleep sleeps for its full time and rmtp is non-NULL, clear it;
sleep(3) expects this, even though it's not a documented property of
nanosleep().

Fixes a problem where sleep() in a threaded program would return
nonzero even on success.
2004-06-24 22:18:11 +00:00
atatat
eaa9fc4cc3 Reverse arguments to fcntl(2). 2004-06-22 13:49:43 +00:00
itojun
5e700978a6 fix missing license. 2004-06-21 21:20:05 +00:00
jmc
b2f782612f Completely rework how tools/compat is done. Purge all uses/references to
_NETBSD_SOURCE as this makes cross building from older/newer versions of
NetBSD harder, not easier (and also makes the resulting tools 'different')

Wrap all required code with the inclusion of nbtool_config.h, attempt to
only use POSIX code in all places (or when reasonable test w. configure and
provide definitions: ala u_int, etc).

Reviewed by lukem. Tested on FreeBSD 4.9, Redhat Linux ES3, NetBSD 1.6.2 x86
NetBSD current (x86 and amd64) and Solaris 9.

Fixes PR's: PR#17762 PR#25944
2004-06-20 22:20:14 +00:00
thorpej
a6ae8a84ac Slight hack to get this building on OS X again: Undo the renaming before
including the host's <pwd.h> to avoid renaming the host's versions of
these functions (which causes a prototype conflict).  After <pwd.h> has
been included, then re-apply the renaming.
2004-06-18 20:34:58 +00:00
christos
92cd5ee20c Don't allow openpty to succeed if the caller is non-superuser.
XXX: we cross-reference ptm 4 which does not exist (yet)
2004-06-18 02:42:57 +00:00
lha
cc333b3dd7 Add list of async-signal-safe functions
Approved by wiz
2004-06-13 19:17:06 +00:00
scw
0f10094026 Cast integer to pointer types via intptr_t.
Problem reported by Havard Eidnes while building evbsh5.
2004-06-11 07:28:05 +00:00
lha
bb3caff139 Expand a little bit on forks behavior in threaded programs
OK by nathanw and martin
2004-06-10 23:45:07 +00:00
martin
7347018381 Ouch. Lint didn't like the last change on sparc64. The reason:
<machine/reg.h> plays dirty naming tricks on sparc64 to allow 32bit
compatibility (reg ->  reg64 and the parameter in
PTHREAD_REG_TO_UCONTEXT() is called reg). This probably needs to be
fixed separately, but for now reordering the includes will do.
2004-06-10 18:06:19 +00:00
uebayasi
0571d32356 Minor fix in SEE ALSO; put xref first; .Pp before a sentence. 2004-06-10 14:01:45 +00:00
uebayasi
f013145702 Split a sentence in SEE ALSO by a .Pp. 2004-06-10 13:58:47 +00:00
uebayasi
12db5f3635 Remove a superfluous .sp in the SEE ALSO section. 2004-06-10 13:53:48 +00:00
kleink
79d01decfe Update for use of uint{16,32}_t. 2004-06-10 11:37:35 +00:00
nathanw
41e871fe18 Avoid depending on declarations of struct reg and struct fpreg by using
the proc_regsize() callback to allocate reg and fpreg buffers as part of the
proc state (lazily initialized by the PT_STATE_RUNNING case of
td_thr_suspend()).

Fixes build on sh3 (and probably sh5) platforms.
2004-06-10 01:38:29 +00:00
christos
4b05f4b58a Jump through taller hoops to provide binary compatibility with programs
compiled with the older and shorter _res. We now use _nres internally
which is the new and bigger one.  We define a _res which is the old
size one if COMPAT__RES is set, and then we consult selected values from
this old _res in res_init(), to emulate the old behavior.
2004-06-09 18:07:03 +00:00
he
552a47b805 Revert previous; mhitch has already committed a workaround to ../Makefile.inc. 2004-06-06 17:09:48 +00:00
he
4b896b2324 It appears necessary to add -I. to CPPFLAGS for nslexer.c. This is
most probably caused by gcc 2.95.3; will be documented in doc/HACKS.
Reviewed by ragge.
2004-06-06 13:26:01 +00:00
ginsbach
9fcbc1ee6b Change remaining K&R style function definition to ANSI; Reviewd by <christos>. 2004-06-04 20:05:25 +00:00
christos
93b9ee2332 simplify and make more efficient (YAMAMOTO Takashi) 2004-06-03 19:32:27 +00:00
mhitch
e1afa110dd A -I. is needed by vax; had gotten removed from elsewhere. 2004-06-03 16:34:19 +00:00