On Mon May 04, Damien Miller wrote:
> Personally, I think seccomp-bpf could be a superior alternative to
> systrace and I'd love to see an implementation. Other developers (inc.
> Theo) are skeptical though, but this is probably a case where the
> argument won't be settled without a concrete implem
I am wondering if the seccomp system call [1] would be welcomed in the
OpenBSD tree. I remember it was among the subjects of last year's Google
Summer of Code. If there is still interest in having it implemented, I
am willing to work on it: I have a diff that creates the system call and
allows secc
hen tries to change the
mode of "$testdir/log" which fails since the file does not exist.
The diff below checks for truncation as suggested in strlcpy(3).
Nicolas Bedos
Index: src/usr.sbin/syslogd/syslogd.c
===
RCS fil
Last update, with Tobias's help.
The following diff
- changes MAXPATHLEN from sys/param.h to PATH_MAX from limits.h
- adds a missing prototype for sane_count
- locate.bigram and locate.code now abort when reading a pathname
exceeding PATH_MAX bytes on stdin
Index: src/usr.bin/locate//bigram
Again, thank you for your suggestions. I didn't thought about factoring
out the len/sizeof comparisons. I have also added the free() call, and
an errx() call when a pathname is too long.
Nicolas Bedos
Index: src/usr.bin/locate//bigram/locate.bigram.c
=
iff. It does indeed look
less 'fragile' !
In locate.code.c 'mbuf' is never free()d: it is only allocated for the
last line of input and after processing this line the program ends. I
hope it is ok.
Nicolas Bedos
Index: src
ardcoding PATH_MAX?
I ran /etc/weekly with the new binaries and didn't notice any
unexpected changes in the locate database.
Nicolas Bedos
Index: src/usr.bin/locate//bigram/locate.bigram.c
===
RCS file: /cvs/src/usr.bin/loca
sizeof(*reverse). For the sake of consistency I also modified the malloc
call on line 145. Regress tests run fine.
Nicolas Bedos
Index: src/bin/systrace/alias.c
===
RCS file: /cvs/src/bin/systrace/alias.c,v
retrieving revision 1.6
di
Ted Unangst wrote:
> I think using sizeof(*dbv) would be the better idiom.
Here's an updated diff, including Tobias Stoeckmann's fix.
Index: src/usr.bin/locate/locate/util.c
===
RCS file: /cvs/src/usr.bin/locate/locate/util.c,v
retr
sponding
diff below. No binary change on amd64 since sizeof(char **) ==
sizeof(char *).
Nicolas Bedos
Index: usr.bin/locate/locate/util.c
===
RCS file: /cvs/src/usr.bin/locate/locate/util.c,v
retrieving revision 1.11
diff -u -p -u -r
The following diff improves type consistency in wc: the return type of
read() is ssize_t, so the type of 'len' should be ssize_t too. There is
no reason for it to be an int.
Nicolas Bedos
Index: src/usr.bin/wc/wc.c
==
11 matches
Mail list logo