Bug 695419 - audisp-remote calls bind() incorrectly
audisp-remote calls bind() incorrectly
Product: Fedora
Classification: Fedora
Component: audit (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Steve Grubb
Fedora Extras Quality Assurance
Depends On:
Blocks: 695605
  Show dependency treegraph
Reported: 2011-04-11 13:10 EDT by Miloslav Trmač
Modified: 2011-04-25 09:12 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 695605 (view as bug list)
Last Closed: 2011-04-25 09:12:45 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Miloslav Trmač 2011-04-11 13:10:45 EDT
Description of problem:

audisp-remote does
>		memset (&address, 0, sizeof(address));
>		address.sin_family = htons(AF_INET);
>		address.sin_port = htons(config.local_port);
>		address.sin_addr.s_addr = htonl(INADDR_ANY);
which shows in strace as

> bind(3, {sa_family=0x200 /* AF_??? */, sa_data="\0<\0\0\0\0\0\0\0\0\0\0\0\0"}, 16) = 0

For some reason the call still succeeds, but a correct invocation would not call htons on AF_INET.
Comment 1 Steve Grubb 2011-04-11 13:26:40 EDT
It works because the audit daemon also has a matching mistake. Fixed in revision 505.
Comment 2 Tomas Mraz 2011-04-12 02:33:47 EDT
And is the daemon really listening on IPv4 port in this case or not?
Comment 3 Steve Grubb 2011-04-25 09:12:45 EDT
2.1.1 is in rawhide and the testing repo which fixes this issue. Thanks for reporting it.

Note You need to log in before you can comment on or make changes to this bug.