FreeBSD Bugzilla – Attachment 221566 Details for
Bug 252673
Read on a SEQPACKET AF_UNIX socket returns the wrong error when disallowed by Capsicum
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
test program
enotcapable.c (text/plain), 353 bytes, created by
Mark Johnston
on 2021-01-14 15:33:37 UTC
(
hide
)
Description:
test program
Filename:
MIME Type:
Creator:
Mark Johnston
Created:
2021-01-14 15:33:37 UTC
Size:
353 bytes
patch
obsolete
>#include <sys/capsicum.h> >#include <sys/socket.h> >#include <err.h> >#include <unistd.h> > >int >main(void) >{ > cap_rights_t rights; > int sd[2]; > char c; > > if (socketpair(AF_UNIX, SOCK_SEQPACKET, 0, sd) != 0) > err(1, "socketpair"); > cap_rights_limit(sd[0], cap_rights_init(&rights, CAP_WRITE)); > if (read(sd[0], &c, 1) != 1) > err(1, "read"); > return (0); >}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 252673
: 221566