Grsecurity on the Desktop
Posted: Tue Sep 20, 2011 12:39 am
Hello everyone. I have installed grsecurity on my desktop via a hardened Gentoo installation. Everything seems to be working perfectly, barring a few minor issues, some of which I have already fixed myself, thanks to TFM. I do have some questions to toss out for those with more knowledge than I.
1. I notice I can not su to root for sys admin tasks. Is this normal? (I've actually two hardened setups with grsecurity and didn't put my user account in the wheel group on the second installation for this reason.) If users can't su to root, that won't turn me away from this. I can see where it would increase security, so am ok with it.
2. From reading the fine manual, I learned that in cases where apps misbehave, it can usually be fixed by 'paxctl -m /path/to/binary'. That's exactly what I did with mplayer, in order to view movies and it worked like a charm. Is that also the 'cure' for apps that are stack smashed? As an example, pcmanfm gets stack-smashed, although this is not a grsecurity error. There's actually already a bug filed against libfm, which pcmanfm relies on. It looks like that lib is responsible for the stack-smash. Would 'paxctl -m pcmanfm' stop the stack smash or would I need to paxctl libfm, or does paxctl have no control of the stack smash at all? It's no issue if I can't use pcmanfm, because rox doesn't have this issue.
3. Does grsecurity restrict automounting? Although I ran Gentoo for 5 years previously, I haven't messed with it for the last couple of years, so I am not sure if I need to setup automounting or if gresecurity restricts it. I really only need automounting for two purposes - burning the occasional CD, and most importantly, mounting flash drives for Gnucash backups.
4. I haven't run gradmin or gradmn or whatever the program is that you run in learning mode to create the policies. I figured it was best to get the above issues corrected first before I stepped there.
Oh and THANK YOU SO MUCH to the developers of Grsecurity. I don't claim to understand how it works and I don't write code, but these ideas seem brilliant to me and particularly the additional layers of permissions on top of the typical Unix rwx permissions. I am not sure that I even need grsecurity in my present situation, but my curiosity in it has got me absolutely HOOKED!
And as far as my installs, I used a vanilla stage3 tarball from a chroot, synced, switched to the hardened profile, rebuilt the toolchain twice, rebuilt the system, then built the world. The checksec.sh script referenced elsewhere in these forums confirms everything is in order in the kernel, binaries and running processes.
1. I notice I can not su to root for sys admin tasks. Is this normal? (I've actually two hardened setups with grsecurity and didn't put my user account in the wheel group on the second installation for this reason.) If users can't su to root, that won't turn me away from this. I can see where it would increase security, so am ok with it.
2. From reading the fine manual, I learned that in cases where apps misbehave, it can usually be fixed by 'paxctl -m /path/to/binary'. That's exactly what I did with mplayer, in order to view movies and it worked like a charm. Is that also the 'cure' for apps that are stack smashed? As an example, pcmanfm gets stack-smashed, although this is not a grsecurity error. There's actually already a bug filed against libfm, which pcmanfm relies on. It looks like that lib is responsible for the stack-smash. Would 'paxctl -m pcmanfm' stop the stack smash or would I need to paxctl libfm, or does paxctl have no control of the stack smash at all? It's no issue if I can't use pcmanfm, because rox doesn't have this issue.
3. Does grsecurity restrict automounting? Although I ran Gentoo for 5 years previously, I haven't messed with it for the last couple of years, so I am not sure if I need to setup automounting or if gresecurity restricts it. I really only need automounting for two purposes - burning the occasional CD, and most importantly, mounting flash drives for Gnucash backups.
4. I haven't run gradmin or gradmn or whatever the program is that you run in learning mode to create the policies. I figured it was best to get the above issues corrected first before I stepped there.
Oh and THANK YOU SO MUCH to the developers of Grsecurity. I don't claim to understand how it works and I don't write code, but these ideas seem brilliant to me and particularly the additional layers of permissions on top of the typical Unix rwx permissions. I am not sure that I even need grsecurity in my present situation, but my curiosity in it has got me absolutely HOOKED!
And as far as my installs, I used a vanilla stage3 tarball from a chroot, synced, switched to the hardened profile, rebuilt the toolchain twice, rebuilt the system, then built the world. The checksec.sh script referenced elsewhere in these forums confirms everything is in order in the kernel, binaries and running processes.