Skip to contentSkip to conversation

audit updates and fixes

GIT PULL Al Viro 3 participants 6 messages Sep 11, 2006 – Sep 13, 2006

lore
Share & tools
lore

Al Viro

author
#0 lore raw

Audit fixes and missing bits; compared to the last attempt there are two added fixes from Amy... Please, pull:
git://git.kernel.org/pub/scm/linux/kernel/git/viro/audit-current.git/ audit.b28

Shortlog:

Al Viro:
syscall classes hookup for ppc and s390
audit: more syscall classes added
audit: AUDIT_PERM support

Amy Griffis:
sanity check audit_buffer
update audit rule change messages

Steve Grubb:
fix ppid bug in 2.6.18 kernel

Diffstat:

 arch/i386/kernel/audit.c           |   28 +++++++++++++++
 arch/ia64/ia32/audit.c             |   26 ++++++++++++++
 arch/ia64/kernel/audit.c           |   35 +++++++++++++++++++
 arch/powerpc/kernel/Makefile       |    2 +
 arch/powerpc/kernel/audit.c        |   66 +++++++++++++++++++++++++++++++++++++
 arch/powerpc/kernel/compat_audit.c |   38 +++++++++++++++++++++
 arch/s390/kernel/Makefile          |    4 +-
 arch/s390/kernel/audit.c           |   66 +++++++++++++++++++++++++++++++++++++
 arch/s390/kernel/compat_audit.c    |   38 +++++++++++++++++++++
 arch/x86_64/ia32/audit.c           |   26 ++++++++++++++
 arch/x86_64/kernel/audit.c         |   35 +++++++++++++++++++
 include/asm-generic/audit_read.h   |    8 ++++
 include/asm-generic/audit_write.h  |   11 ++++++
 include/linux/audit.h              |   11 ++++++
 kernel/audit.c                     |    6 +++
 kernel/audit.h                     |    1 
 kernel/auditfilter.c               |   37 +++++++++++++++++---
 kernel/auditsc.c                   |   51 ++++++++++++++++++++++++++++
 18 files changed, 483 insertions(+), 6 deletions(-)
#1 lore raw
Quoted 3 lines · On Mon, 11 Sep 2006 18:37:49 +0100 Al Viro <[email protected]> wrote:

Audit fixes and missing bits; compared to the last attempt there are two added fixes from Amy... Please, pull:
git://git.kernel.org/pub/scm/linux/kernel/git/viro/audit-current.git/ audit.b28

This seems a bit.... late.

The patch adds a whole bunch of new extern-decls-in-C. It'd be nice to get those into a header file sometime.

And sparc64 allmodconfig broke.

kernel/built-in.o(.text+0x36834): In function `audit_filter_rules':
: undefined reference to `audit_classify_syscall'
make: *** [.tmp_vmlinux1] Error 1

Possibly because the audit git tree fell out of -mm ages ago, partly because its owner (ahem) ignored my request to resync it with upstream. I have new scripts from Junio and shall try again.

author
#2 lore raw

Duh... Two trivial fixes:
* make sure that all non-biarch targets get hookup.
* deal with sparc64 correctly.

[ObGit: git-diff after git-mv + modify a couple of lines generates deletion+new file instead of rename. Weird...]

Please, pull from git.kernel.org/pub/scm/linux/kernel/git/viro/audit-current.git/ audit.b29

Al Viro:
syscall class hookup for all normal targets
sparc64 audit syscall classes hookup

 arch/i386/kernel/audit.c             |   51 ---------------------------
 b/arch/i386/kernel/Makefile          |    1
 b/arch/ia64/Kconfig                  |    4 ++
 b/arch/powerpc/Kconfig               |    4 ++
 b/arch/s390/Kconfig                  |    4 ++
 b/arch/sparc64/Kconfig               |    4 ++
 b/arch/sparc64/kernel/Makefile       |    3 +
 b/arch/sparc64/kernel/audit.c        |   66 +++++++++++++++++++++++++++++++++++
 b/arch/sparc64/kernel/compat_audit.c |   37 +++++++++++++++++++
 b/arch/x86_64/Kconfig                |    4 ++
 b/lib/Kconfig                        |    5 ++
 b/lib/Makefile                       |    1
 b/lib/audit.c                        |   53 ++++++++++++++++++++++++++++
 13 files changed, 185 insertions(+), 52 deletions(-)
#3 lore raw
Quoted 3 lines · Al Viro

[ObGit: git-diff after git-mv + modify a couple of lines generates deletion+new file instead of rename. Weird...]

No it doesn't.

Are you sure you used the "-M" flag to ask for renames?

The other alternative is that the file was so small that the change is considered significant, and it becomes a rewrite.

Linus

#4 lore raw
In reply to Al Viro
Quoted 15 lines · Al Viro
 arch/i386/kernel/audit.c             |   51 ---------------------------
 b/arch/i386/kernel/Makefile          |    1
 b/arch/ia64/Kconfig                  |    4 ++
 b/arch/powerpc/Kconfig               |    4 ++
 b/arch/s390/Kconfig                  |    4 ++
 b/arch/sparc64/Kconfig               |    4 ++
 b/arch/sparc64/kernel/Makefile       |    3 +
 b/arch/sparc64/kernel/audit.c        |   66 +++++++++++++++++++++++++++++++++++
 b/arch/sparc64/kernel/compat_audit.c |   37 +++++++++++++++++++
 b/arch/x86_64/Kconfig                |    4 ++
 b/lib/Kconfig                        |    5 ++
 b/lib/Makefile                       |    1
 b/lib/audit.c                        |   53 ++++++++++++++++++++++++++++
 13 files changed, 185 insertions(+), 52 deletions(-)

Btw, if you do "git diff --stat --summary -M", you'd have gotten

 arch/i386/kernel/Makefile          |    1 -
 arch/ia64/Kconfig                  |    4 ++
 arch/powerpc/Kconfig               |    4 ++
 arch/s390/Kconfig                  |    4 ++
 arch/sparc64/Kconfig               |    4 ++
 arch/sparc64/kernel/Makefile       |    3 ++
 arch/sparc64/kernel/audit.c        |   66 ++++++++++++++++++++++++++++++++++++
 arch/sparc64/kernel/compat_audit.c |   37 ++++++++++++++++++++
 arch/x86_64/Kconfig                |    4 ++
 lib/Kconfig                        |    5 +++
 lib/Makefile                       |    1 +
 {arch/i386/kernel => lib}/audit.c  |    2 +
 12 files changed, 134 insertions(+), 1 deletions(-)
 create mode 100644 arch/sparc64/kernel/audit.c
 create mode 100644 arch/sparc64/kernel/compat_audit.c
 rename arch/i386/kernel/audit.c => lib/audit.c (97%)

instead, which is much nicer. It shows the rename, and the summary info also points out that some of the files were newly created.

Linus

author
#5 lore raw
Quoted 34 lines · Linus Torvalds
Quoted 6 lines
 arch/i386/kernel/audit.c             |   51 ---------------------------
 b/arch/i386/kernel/Makefile          |    1
 b/arch/ia64/Kconfig                  |    4 ++
 b/arch/powerpc/Kconfig               |    4 ++
 b/arch/s390/Kconfig                  |    4 ++
 b/arch/sparc64/Kconfig               |    4 ++
Quoted 8 lines
 b/arch/sparc64/kernel/Makefile       |    3 +
 b/arch/sparc64/kernel/audit.c        |   66 +++++++++++++++++++++++++++++++++++
 b/arch/sparc64/kernel/compat_audit.c |   37 +++++++++++++++++++
 b/arch/x86_64/Kconfig                |    4 ++
 b/lib/Kconfig                        |    5 ++
 b/lib/Makefile                       |    1
 b/lib/audit.c                        |   53 ++++++++++++++++++++++++++++
 13 files changed, 185 insertions(+), 52 deletions(-)

Btw, if you do "git diff --stat --summary -M", you'd have gotten

 arch/i386/kernel/Makefile          |    1 -
 arch/ia64/Kconfig                  |    4 ++
 arch/powerpc/Kconfig               |    4 ++
 arch/s390/Kconfig                  |    4 ++
 arch/sparc64/Kconfig               |    4 ++
 arch/sparc64/kernel/Makefile       |    3 ++
 arch/sparc64/kernel/audit.c        |   66 ++++++++++++++++++++++++++++++++++++
 arch/sparc64/kernel/compat_audit.c |   37 ++++++++++++++++++++
 arch/x86_64/Kconfig                |    4 ++
 lib/Kconfig                        |    5 +++
 lib/Makefile                       |    1 +
 {arch/i386/kernel => lib}/audit.c  |    2 +
 12 files changed, 134 insertions(+), 1 deletions(-)
 create mode 100644 arch/sparc64/kernel/audit.c
 create mode 100644 arch/sparc64/kernel/compat_audit.c
 rename arch/i386/kernel/audit.c => lib/audit.c (97%)
Quoted 2 lines

instead, which is much nicer. It shows the rename, and the summary info also points out that some of the files were newly created.

I see... FWIW, I'd been using git diff fed through diffstat(1) for that part. Thanks, that's indeed much better.

ObMIPS: how many ABI do we have there, anyway? 4 + IRIX compat? More?