gradm problem

Discuss usability issues, general maintenance, and general support issues for a grsecurity-enabled system.

gradm problem

Postby lego_12239 » Sun Feb 26, 2012 5:56 am

Hi, all.

I have debian 6.0 with 2.6.32.57 and 3.2.7 vanilla kernels patched with grsecurity patch. I got gradm 2.9 source from grsecurity.net. When I tried to do gradm -F -L /etc/grsec/learning.logs, i got next message on a console:

Code: Select all
You are using incompatible versions of gradm and grsecurity.
Please update both versions to the ones available on the website.
Make sure your gradm has been compiled for the kernel you are currently running.


and in dmesg:

Code: Select all
grsec: From 192.168.1.1: /dev/grsec: 12 bytes sent 16 required, being fed garbaged by /sbin/gradm[gradm:1161] uid/euid:0/0 gid/egid:0/0, parent /bin/bash[bash:1157] uid/euid:0/0 gid/egid:0/0
grsec: From 192.168.1.1: /dev/grsec: 12 bytes sent 16 required, being fed garbaged by /sbin/gradm[gradm:1161] uid/euid:0/0 gid/egid:0/0, parent /bin/bash[bash:1157] uid/euid:0/0 gid/egid:0/0


This messages are the same on both kernels. What do i make wrong?

I have 64 bit kernels and 32 bit userland, so i made next changes in Makefile of gradm:
Code: Select all
-LIBS := $(shell if [ "`uname -m`" != "sparc64" -a "`uname -m`" != "x86_64" ]; then echo "-lfl"
; else echo "" ; fi)
-OPT_FLAGS := $(shell if [ "`uname -m`" != "sparc64" ] && [ "`uname -m`" != "x86_64" ]; then echo "-O2" ; else echo "-O2 -m64" ; fi)
+#LIBS := $(shell if [ "`uname -m`" != "sparc64" -a "`uname -m`" != "x86_64" ]; then echo "-lfl" ; else echo "" ; fi)
+LIBS := -lfl
+#OPT_FLAGS := $(shell if [ "`uname -m`" != "sparc64" ] && [ "`uname -m`" != "x86_64" ]; then echo "-O2" ; else echo "-O2 -m64" ; fi)
+OPT_FLAGS := -O2
lego_12239
 
Posts: 4
Joined: Sun Feb 26, 2012 5:03 am

Re: gradm problem

Postby spender » Sun Feb 26, 2012 6:13 pm

Did that change fix your problem?

-Brad
spender
 
Posts: 2185
Joined: Wed Feb 20, 2002 8:00 pm

Re: gradm problem

Postby lego_12239 » Mon Feb 27, 2012 2:08 am

No. This was a step to simply make gradm in my 32 bit userland. Without it gradm refused to compile at all.

But, I forgot to say that grlearn run after this command regardless of this error message.
lego_12239
 
Posts: 4
Joined: Sun Feb 26, 2012 5:03 am

Re: gradm problem

Postby spender » Mon Feb 27, 2012 8:27 am

Can you show me the output of: 'file /sbin/gradm'?

-Brad
spender
 
Posts: 2185
Joined: Wed Feb 20, 2002 8:00 pm

Re: gradm problem

Postby lego_12239 » Mon Feb 27, 2012 4:01 pm

Code: Select all
/sbin/gradm: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.18, stripped
lego_12239
 
Posts: 4
Joined: Sun Feb 26, 2012 5:03 am

Re: gradm problem

Postby spender » Mon Feb 27, 2012 4:17 pm

You need to be able to build a 64bit version of gradm, which is what the Makefile was designed to do. gradm currently requires itself to be 64bit when run on a 64bit kernel.

-Brad
spender
 
Posts: 2185
Joined: Wed Feb 20, 2002 8:00 pm

Re: gradm problem

Postby lego_12239 » Tue Feb 28, 2012 3:23 pm

In 64 bit Debian it work. gradm -S show me:

Code: Select all
The RBAC system is currently enabled


But grlearn is not running. Is it ok?
lego_12239
 
Posts: 4
Joined: Sun Feb 26, 2012 5:03 am

Re: gradm problem

Postby spender » Tue Feb 28, 2012 8:31 pm

You won't be able to see grlearn except in the admin role.

-Brad
spender
 
Posts: 2185
Joined: Wed Feb 20, 2002 8:00 pm


Return to grsecurity support

cron