diff options
author | Huw Davies <huw@codeweavers.com> | 2016-06-27 15:05:29 -0400 |
---|---|---|
committer | Paul Moore <paul@paul-moore.com> | 2016-06-27 15:05:29 -0400 |
commit | e1adea927080821ebfa7505bff752a4015955660 (patch) | |
tree | adbbbe9962bf497bdf119849a37c8bbcc1eea034 /include/net | |
parent | 56ac42bc94b18d45b6c484edeac33be86bfb3efa (diff) |
calipso: Allow request sockets to be relabelled by the lsm.
Request sockets need to have a label that takes into account the
incoming connection as well as their parent's label. This is used
for the outgoing SYN-ACK and for their child full-socket.
Signed-off-by: Huw Davies <huw@codeweavers.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
Diffstat (limited to 'include/net')
-rw-r--r-- | include/net/netlabel.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/net/netlabel.h b/include/net/netlabel.h index 918a6044c89c..a2408c30a7f7 100644 --- a/include/net/netlabel.h +++ b/include/net/netlabel.h | |||
@@ -229,6 +229,8 @@ struct netlbl_lsm_secattr { | |||
229 | * @sock_getattr: retrieve the socket's attr | 229 | * @sock_getattr: retrieve the socket's attr |
230 | * @sock_setattr: set the socket's attr | 230 | * @sock_setattr: set the socket's attr |
231 | * @sock_delattr: remove the socket's attr | 231 | * @sock_delattr: remove the socket's attr |
232 | * @req_setattr: set the req socket's attr | ||
233 | * @req_delattr: remove the req socket's attr | ||
232 | * | 234 | * |
233 | * Description: | 235 | * Description: |
234 | * This structure is filled out by the CALIPSO engine and passed | 236 | * This structure is filled out by the CALIPSO engine and passed |
@@ -252,6 +254,10 @@ struct netlbl_calipso_ops { | |||
252 | const struct calipso_doi *doi_def, | 254 | const struct calipso_doi *doi_def, |
253 | const struct netlbl_lsm_secattr *secattr); | 255 | const struct netlbl_lsm_secattr *secattr); |
254 | void (*sock_delattr)(struct sock *sk); | 256 | void (*sock_delattr)(struct sock *sk); |
257 | int (*req_setattr)(struct request_sock *req, | ||
258 | const struct calipso_doi *doi_def, | ||
259 | const struct netlbl_lsm_secattr *secattr); | ||
260 | void (*req_delattr)(struct request_sock *req); | ||
255 | }; | 261 | }; |
256 | 262 | ||
257 | /* | 263 | /* |