[apparmor] [patch] make parser's definition of allowed var names consistent

Christian Boltz apparmor at cboltz.de
Fri Apr 1 19:32:54 UTC 2011


Hello,

Am Freitag, 1. April 2011 schrieb Steve Beattie:
> On Thu, Mar 31, 2011 at 11:14:55PM +0200, Christian Boltz wrote:
> > Am Donnerstag, 31. März 2011 schrieb Steve Beattie:
> > > On Thu, Mar 31, 2011 at 08:12:32PM +0200, Christian Boltz wrote:
> > > > Am Mittwoch, 30. März 2011 schrieb Christian Boltz:
> > > Trunk has the shortcut lp:apparmor (or alternatively
> > > 
> > > bzr+ssh://bazaar.launchpad.net/+branch/apparmor/), so you can do:
> > >   bzr checkout lp:apparmor
> > 
> > OK, that worked (after finding out how to set a sane userid in
> > launchpad and where the SSH key upload is hidden - is it really
> > only linked on some help.launchpad.net pages?
> 
> Bah, sorry, I meant to mention the ssh key bit. 

No problem - you don't need to hold my hand on every small step ;-)

> You can
> see what keys you have registered from your launchpad
> home page https://launchpad.net/~[YourLPID] (in your case
> https://launchpad.net/~cboltz ); 

Yes, that's easy to find, however...

> the direct link for adding/removing
> is https://launchpad.net/~[YourLPID]/+editsshkeys .

... this one is not linked on the launchpad profile page :-/

Looks like I have to report a bug against launchpad itsself - I hope the 
launchpad team is more responsive than the bnc team... (At least it's a 
typical thing for me - before I'm really using launchpad, I file the 
first bugreport to say hello *g*)

> > I'd prefer to use a separate (sub)directory so that
> > a) apparmor.vim stuff doesn't conflict with something else
> > b) I don't have too many (unrelated) files lying around
> > 
> > What about utils/apparmor_vim/ ?
> 
> Maybe just utils/vim/ ? The 'apparmor_' bit is just redundant for a
> directory name.

I'm OK with utils/vim/. If nobody objects, I'll commit the apparmor.vim 
related files there in the next days.

> > To give you an idea: my current directory with apparmor.vim looks
> > like this (with some comments on what the files are/do):
> > 
> > directly related to apparmor.vim:
> > -rw-r--r-- 1 cb users 15519 28. Mär 13:23 apparmor.vim
> > -rw-r--r-- 1 cb users 11689 28. Mär 13:23 apparmor.vim.in
> > -rwxr-xr-x 1 cb users  5322 11. Jan 16:46 make
> > -rw-r--r-- 1 cb users    53 11. Jan 16:44 Makefile
> 
> What's the difference between make and Makefile here? Is make a shell
> script that does the actual work?

Exactly (maybe I should rename the "make" script to something more 
intuitive - probably "make_apparmor.vim")

The Makefile is only there to allow typing "make" instead
of "./make" ;-)  

> > some test profiles and sniplets - some with valid, some with
> > intentionally broken syntax (to test detection of invalid rules):
...
> A tests/ (or similar) subdirectory below vim/ probably makes
> sense for those. 

Indeed, good idea.

> (I wonder if we could rig up something like
> http://blog.nix.is/testing-vim-syntax-files to automate testing.)

Looks interesting and like a good idea. 
I'm usually testing by opening the test profiles in vim and looking at 
them, but automation is always good - and even finds things I overlook.

[generating list of network protocols]
> Sure. Really, all that would happen is that the top level 'make
> setup' target would invoke make (or make apparmor.vim) in the
> utils/vim/ directory.

Sounds good. Since I'm not really familiar with the kernel headers, can 
you please provide a script that gives me a list of network protocols 
based on the kernel headers?

BTW: In an earlier mail, I wrote:
| if I  get http://wiki.bazaar.canonical.com/BzrForSVNUsers right, it is
| basically s/svn/bzr/ for the commands I need :-)  (too bad that bash
| doesn't allow aliases based on the working directory...)

Linux wouldn't be linux if...

# cat ~/bin/svn
#!/bin/bash
command=/usr/bin/svn
pwd | grep -q ^/home/cb/apparmor && command=/usr/bin/bzr
exec $command "$@"

*g*


Regards,

Christian Boltz
-- 
dU hAsT nAtUeRlIcH rEcHt. MaN mUsS sIcH bEiM lEsEn NuR dArAn GeWoEhNeN.
mAcHt DaNn KeInEn UnTeRsChIeD mEhR.       [Andreas Kneib in suse-linux]



More information about the AppArmor mailing list