Re: [PATCH] Smackv10: Smack rules grammar + their stateful parser(2)

2007-11-10 Thread Ahmed S. Darwish
) { + objectstr[*label_len] = '\0'; + *label_len = 0; + } Same applies here. / jakob Good spots, thanks a lot for the review. Regards, -- Ahmed S. Darwish Homepage: http://darwish.07.googlepages.com Blog: http://darwish-07

Re: [PATCH] Smackv10: Smack rules grammar + their stateful parser

2007-11-06 Thread Ahmed S. Darwish
labels are represented in ASCII characters, they cannot contain unprintable characters or the '/' (slash) character. and in write(): if (!isascii(c) return -EINVAL; if (!isspace(c) !isgraph(c)) return -EINVAL; This satisfy above customized labels rule, right ? Regards, -- Ahmed S. Darwish Homepage

Re: [PATCH] Smackv10: Smack rules grammar + their stateful parser

2007-11-06 Thread Ahmed S. Darwish
On 11/6/07, Adrian Bunk [EMAIL PROTECTED] wrote: On Tue, Nov 06, 2007 at 01:34:05PM +0200, Ahmed S. Darwish wrote: Hi, On Tue, Nov 06, 2007 at 09:56:51AM +0100, Adrian Bunk wrote: On Tue, Nov 06, 2007 at 03:26:12AM -0500, Kyle Moffett wrote: On Nov 06, 2007, at 01:33:05, Adrian Bunk

Re: [PATCH] Smackv10: Smack rules grammar + their stateful parser

2007-11-05 Thread Ahmed S. Darwish
On Sun, Nov 04, 2007 at 12:28:48PM +, Pavel Machek wrote: Hi! Still to come: - Final cleanup of smack_load_write and smack_cipso_write. Hi All, After agreeing with Casey on the load input grammar yesterday, here's the final grammar and its parser (which needs more

Re: [PATCH] Smackv10: Smack rules grammar + their stateful parser

2007-11-05 Thread Ahmed S. Darwish
On 11/5/07, Linus Torvalds [EMAIL PROTECTED] wrote: On Mon, 5 Nov 2007, Ahmed S. Darwish wrote: On Sun, Nov 04, 2007 at 12:28:48PM +, Pavel Machek wrote: Can we avoid string parsers in the kernel? Ok, Could someone suggest a better idea please ?. I personally think string

Re: [PATCH] Smackv10: Smack rules grammar + their stateful parser

2007-11-04 Thread Ahmed S. Darwish
On 11/3/07, Ahmed S. Darwish [EMAIL PROTECTED] wrote: static int smk_open_load(struct inode *inode, struct file *file) { - return seq_open(file, load_seq_ops); + if ((file-f_flags O_ACCMODE) == O_RDONLY) + return seq_open(file, load_seq_ops

Re: [PATCH] Smackv10: Smack rules grammar + their stateful parser

2007-11-03 Thread Ahmed S. Darwish
On 11/3/07, Kyle Moffett [EMAIL PROTECTED] wrote: On Nov 03, 2007, at 12:43:06, Ahmed S. Darwish wrote: Bashv3 builtin echo behaves very strangely to -EINVAL. It sends all the buffers that causes -EINVAL again in subsequent echo invocations. i.e. echo Invalid Rule /smack/load

Re: [PATCH] Smackv9: Use a stateful parser for parsing Smack rules

2007-11-02 Thread Ahmed S. Darwish
On 11/1/07, Jan Engelhardt [EMAIL PROTECTED] wrote: On Nov 1 2007 17:54, Ahmed S. Darwish wrote: + +static inline int isblank(char c) +{ + return (c == ' ' || c == '\t'); +} Use isspace(). isspace accepts newlines and carriage-returns too which is not accepted between elements

[PATCH] Smackv9: Use a stateful parser for parsing Smack rules

2007-11-01 Thread Ahmed S. Darwish
(void) } } + sema_init(smack_write_sem, 1); smk_cipso_doi(); return err; -- Ahmed S. Darwish Homepage: http://darwish.07.googlepages.com Blog: http://darwish-07.blogspot.com - To unsubscribe from this list: send the line unsubscribe linux-security

Re: [PATCH 2/2] Version 9 (2.6.24-rc1) Smack: Simplified Mandatory Access Control Kernel

2007-10-27 Thread Ahmed S. Darwish
was passed a non-cipso label. Signed-off-by: Ahmed S. Darwish [EMAIL PROTECTED] --- smackv8-omit-noncipso-in-seq-start.patch diff --git a/security/smack/smackfs.c b/security/smack/smackfs.c index 55ba2dc..b061cd0 100644 --- a/security/smack/smackfs.c +++ b/security/smack/smackfs.c @@ -297,14 +297,22

Re: [PATCH 2/2] Version 9 (2.6.24-rc1) Smack: Simplified Mandatory Access Control Kernel

2007-10-27 Thread Ahmed S. Darwish
now if you agree on this. Regards, -- Ahmed S. Darwish HomePage: http://darwish.07.googlepages.com Blog: http://darwish-07.blogspot.com - To unsubscribe from this list: send the line unsubscribe linux-security-module in the body of a message to [EMAIL PROTECTED] More majordomo info at http

[PATCH] Smackv8: Safe lockless {cipso,load} read operation

2007-10-20 Thread Ahmed S. Darwish
Hi, Utilizing Al's concers about using smack_cipso_count without locking, here's a patch that remove smack_cipso_count and uses simple list traversing in read() without any counting mechanism. CC: Al Viro [EMAIL PROTECTED] Signed-off-by: Ahmed S. Darwish [EMAIL PROTECTED] --- Please apply

Re: [PATCH] Version 8 (2.6.23) Smack: Simplified Mandatory Access Control Kernel

2007-10-19 Thread Ahmed S. Darwish
we don't do a write operation depending on that read, right ?. -- Ahmed S. Darwish Homepage: http://darwish.07.googlepages.com Blog: http://darwish-07.blogspot.com - To unsubscribe from this list: send the line unsubscribe linux-security-module in the body of a message to [EMAIL PROTECTED] More

Re: [PATCH] Version 7 (2.6.23) Smack: Simplified Mandatory Access Control Kernel

2007-10-14 Thread Ahmed S. Darwish
-196.218.207.18.tedata.net: ICMP parameter problem - octet 20, length 48 Best Regards, -- Ahmed S. Darwish HomePage: http://darwish.07.googlepages.com Blog: http://darwish-07.blogspot.com - To unsubscribe from this list: send the line unsubscribe linux-security-module in the body of a message