• R/O
  • SSH
  • HTTPS

tomoyo: Commit


Commit MetaInfo

Revision3088 (tree)
Time2009-10-05 15:45:53
Authorkumaneko

Log Message

Fix size truncation bug at ccs_memcmp().

Change Summary

Incremental Difference

--- trunk/2.3.x/tomoyo-lsm/patches/tomoyo-add-internal-header.patch (revision 3087)
+++ trunk/2.3.x/tomoyo-lsm/patches/tomoyo-add-internal-header.patch (revision 3088)
@@ -1241,8 +1241,8 @@
12411241 + return a->hash != b->hash || strcmp(a->name, b->name);
12421242 +}
12431243 +
1244-+static inline int tomoyo_memcmp(void *a, void *b, const u8 offset,
1245-+ const u8 size)
1244++static inline int tomoyo_memcmp(void *a, void *b, const size_t offset,
1245++ const size_t size)
12461246 +{
12471247 + return memcmp(((char *) a) + offset, ((char *) b) + offset,
12481248 + size - offset);
--- trunk/1.7.x/ccs-patch/security/ccsecurity/internal.h (revision 3087)
+++ trunk/1.7.x/ccs-patch/security/ccsecurity/internal.h (revision 3088)
@@ -992,7 +992,8 @@
992992 return a->hash != b->hash || strcmp(a->name, b->name);
993993 }
994994
995-static inline int ccs_memcmp(void *a, void *b, const u8 offset, const u8 size)
995+static inline int ccs_memcmp(void *a, void *b, const size_t offset,
996+ const size_t size)
996997 {
997998 return memcmp(((char *) a) + offset, ((char *) b) + offset,
998999 size - offset);
--- tags/lkml/16/tomoyo-add-internal-header.patch (revision 3087)
+++ tags/lkml/16/tomoyo-add-internal-header.patch (revision 3088)
@@ -1241,8 +1241,8 @@
12411241 + return a->hash != b->hash || strcmp(a->name, b->name);
12421242 +}
12431243 +
1244-+static inline int tomoyo_memcmp(void *a, void *b, const u8 offset,
1245-+ const u8 size)
1244++static inline int tomoyo_memcmp(void *a, void *b, const size_t offset,
1245++ const size_t size)
12461246 +{
12471247 + return memcmp(((char *) a) + offset, ((char *) b) + offset,
12481248 + size - offset);
Show on old repository browser