Skip to contentSkip to conversation

Associate attribute with another attribute?

refpolicy Mladen Sekara 4 participants 5 messages May 24, 2014 – May 27, 2014

lore
Share & tools
lore
#0 lore raw

Can attribute be associated with another attribute, the same way that is done with type(s)?

eg. If we associate attributes with types using: "type mytype1_t, my_attribute1, my_attribute2...;",

can we associate attributes with attributes using: "attribute my_attribute0, my_attribute1, my_attribute2...;", or something similar?

Signature · 1 line
Mladen Sekara <[email protected]>
#1 lore raw
Quoted 9 lines · Mladen Sekara

Can attribute be associated with another attribute, the same way that is done with type(s)?

eg. If we associate attributes with types using: "type mytype1_t, my_attribute1, my_attribute2...;",

can we associate attributes with attributes using: "attribute my_attribute0, my_attribute1, my_attribute2...;", or something similar?

No, although it would be great if it could.

#3 lore raw
In reply to Mladen Sekara
Quoted 9 lines · Mladen Sekara

Can attribute be associated with another attribute, the same way that is done with type(s)?

eg. If we associate attributes with types using: "type mytype1_t, my_attribute1, my_attribute2...;",

can we associate attributes with attributes using: "attribute my_attribute0, my_attribute1, my_attribute2...;", or something similar?

Not with reference policy but it is possible with CIL policy.

Do not ask me how they achieve that though because i do not know.

I suppose that they expand the attributes before the resulting policy gets translated to policy the kernel understands because i think it is a limitation is the kernel policy language.

Not that it matters much though, it is handy nevertheless.

#2 lore raw
In reply to Daniel J Walsh

Ah, OK.
Probably not needed very often, but in same cases it could save some time.

Thanks.

Signature · 1 line
Mladen Sekara <[email protected]>
Quoted 11 lines · Daniel J Walsh
Quoted 9 lines · Mladen Sekara

Can attribute be associated with another attribute, the same way that is done with type(s)?

eg. If we associate attributes with types using: "type mytype1_t, my_attribute1, my_attribute2...;",

can we associate attributes with attributes using: "attribute my_attribute0, my_attribute1, my_attribute2...;", or something similar?

No, although it would be great if it could.

#4 lore raw
In reply to Dominick Grift
Quoted 13 lines · Dominick Grift
Quoted 9 lines · Mladen Sekara

Can attribute be associated with another attribute, the same way that is done with type(s)?

eg. If we associate attributes with types using: "type mytype1_t, my_attribute1, my_attribute2...;",

can we associate attributes with attributes using: "attribute my_attribute0, my_attribute1, my_attribute2...;", or something similar?

Not with reference policy but it is possible with CIL policy.

Quoted 7 lines

Do not ask me how they achieve that though because i do not know.

I suppose that they expand the attributes before the resulting policy gets translated to policy the kernel understands because i think it is a limitation is the kernel policy language.

Not that it matters much though, it is handy nevertheless.

Eventually I'd like to make a proper refpolicy high level language on top of CIL, when CIL gets merged. Then it would allow all of the nice features in refpolicy that we all want.

Signature · 3 lines
Chris PeBenito
Tresys Technology, LLC
www.tresys.com | oss.tresys.com