Questions regarding labeled ipsec/MAC networking
I am finishing up the internet-drafts for labeled ipsec. The ipsec RFCs have been updated and I have a question about how one of the new features in one of the updated rfcs should work with labeled ipsec or MAC networking in general.
1. rfc 4301 - IP Security Architecture introduces and describes a Populate From Packet (PFP) flag on page 23.
When creating a new SA, the PFP flag is used to determine whether the value for the selector of the new SA will come from the packet that triggered the SA's creation or from the SPD entry. For example, the source address is a selector. An outbound packet finds an SPD entry, but no SA, so must create an SA. Currently, we take packet's source address and use this as source address when negotiating and creating new SA.
However, according to rfc 4301, PFP flag can be set and then used to decide whether newly created SA's source address selector might come from the packet or from the SPD entry.
My concern is that security context is described in draft as a selector, thus I need to consider PFP flag. Do we want PFP-flag capability for security context selector? For example, in current selinux policy, ipsec_spd_t:s0 is default SPD entry label.
Let's say sshd triggers SA creation with sshd_t:s0. Currently, new SA will be created with sshd_t:s0. However, with PFP capability, new SA being created could have sshd_t:s0 or ipsec_spd_t:s0 depending on what PFP-flag is set to?
In the example, to create the SA with ipsec_spd_t seems like a relabel to me. Do we want this to ever happen? At first I thought it could be used to map data to certain labels, that is the label in the SPD entry... but I don't know if this is a desired thing in MAC networking? Do we want to disable using PFP flag for security context and always take label from socket triggering SA creation as done currently?
I have another question:
2. Security Gateways in MAC networking.
In obsoleted rfc 2401 -IP Security Architecture, section 8.6 described an MLS security gateway using IPsec as:
"a security gateway acting as an outbound proxy, creating SAs for MLS
systems that originate packets forwarded by the gateway. These MLS systems may explicitly label the packets to be forwarded, or the whole originating network may have sensitivity characteristics associated with it. The security gateway MUST create and use appropriate SAs for AH, ESP or both, to protect such traffic it forwards.
Similarly such a gateway SHOULD accept and process inbound AH and/or ESP packets and forward appropriately, using explicit packet labeling, or relying on the sensitivity characteristics of the destination network."
All mention of MLS networking as in rfc 2401 was left out in rfc 4301. So I want to reintroduce it as MAC networking instead.
Do we want to consider labeled ipsec for security gateways in MAC networking? There would be 2 cases that I can think of.
1. machines behind the security gateway that explicitly label the packets (CIPSO). This is stated above.
In this case above text is still applicable.
2. The whole originating network has a security context associated with it. In this case, packets from machines behind the security gateway are not explicitly labeled. These machines send their packets to security security gateway to be forwarded. This incoming interface of the security gateway is labeled. All packets arriving on it (from machines behind the gateway) would be marked with this label. And that would be the label used to negotiate and create the SAs for the packets originating from behind the gateway.
Is this acceptable MAC networking for security gateways?
Sorry, for the long email. I hope I have been clear, but if not, please let me know.
Thanks!!
regards,
Joy
--
This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Quoted 10 lines · Joy Latten
2. The whole originating network has a security context associated with it. In this case, packets from machines behind the security gateway are not explicitly labeled. These machines send their packets to security security gateway to be forwarded. This incoming interface of the security gateway is labeled. All packets arriving on it (from machines behind the gateway) would be marked with this label. And that would be the label used to negotiate and create the SAs for the packets originating from behind the gateway.
Is this acceptable MAC networking for security gateways?
I don't think we should be specifying that this is the only possible model for classifying packets and applying labels. Any number of attributes can be used for packet classification (ports, addresses, protocols etc.), and labels applied to SAs does not have to be directly related to local label.
There may also be finer graine external labeling than "whole network", so I think that needs to be generalized, too. e.g. something like, the gateway MAY utilize various attributes of the traffic and existing security labels to determine labels for SAs to be applied.
Signature · 7 lines
James Morris <[email protected]> -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Quoted 18 lines · James Morris
Quoted 10 lines · Joy Latten
2. The whole originating network has a security context associated with it. In this case, packets from machines behind the security gateway are not explicitly labeled. These machines send their packets to security security gateway to be forwarded. This incoming interface of the security gateway is labeled. All packets arriving on it (from machines behind the gateway) would be marked with this label. And that would be the label used to negotiate and create the SAs for the packets originating from behind the gateway.
Is this acceptable MAC networking for security gateways?
I don't think we should be specifying that this is the only possible model for classifying packets and applying labels. Any number of attributes can be used for packet classification (ports, addresses, protocols etc.), and labels applied to SAs does not have to be directly related to local label.
Quoted 4 lines
There may also be finer graine external labeling than "whole network", so I think that needs to be generalized, too. e.g. something like, the gateway MAY utilize various attributes of the traffic and existing security labels to determine labels for SAs to be applied.
Ah, ok, I like your generalization. So, in other words, labeled ipsec can be applied in security gateway, but leave it up to implementation to determine how to label the traffic from the machines behind the security gateway that may not be enforcing MAC and/or how to derive label for SA.
Thanks!!
regards,
Joy
--
This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Quoted 28 lines · Joy Latten
I am finishing up the internet-drafts for labeled ipsec. The ipsec RFCs have been updated and I have a question about how one of the new features in one of the updated rfcs should work with labeled ipsec or MAC networking in general.
1. rfc 4301 - IP Security Architecture introduces and describes a Populate From Packet (PFP) flag on page 23.
When creating a new SA, the PFP flag is used to determine whether the value for the selector of the new SA will come from the packet that triggered the SA's creation or from the SPD entry. For example, the source address is a selector. An outbound packet finds an SPD entry, but no SA, so must create an SA. Currently, we take packet's source address and use this as source address when negotiating and creating new SA.
However, according to rfc 4301, PFP flag can be set and then used to decide whether newly created SA's source address selector might come from the packet or from the SPD entry.
My concern is that security context is described in draft as a selector, thus I need to consider PFP flag. Do we want PFP-flag capability for security context selector? For example, in current selinux policy, ipsec_spd_t:s0 is default SPD entry label.
Let's say sshd triggers SA creation with sshd_t:s0. Currently, new SA will be created with sshd_t:s0. However, with PFP capability, new SA being created could have sshd_t:s0 or ipsec_spd_t:s0 depending on what PFP-flag is set to?
Quoted 6 lines
In the example, to create the SA with
ipsec_spd_tseems like a relabel to me. Do we want this to ever happen? At first I thought it could be used to map data to certain labels, that is the label in the SPD entry... but I don't know if this is a desired thing in MAC networking? Do we want to disable using PFP flag for security context and always take label from socket triggering SA creation as done currently?
I don't think we want to support taking the label from the SPD entry; or if we did, I think it would be a separate label from the normal SPD label - one specifically dedicated to being applied to SAs.
Quoted 20 lines
I have another question:
2. Security Gateways in MAC networking.
In obsoleted rfc 2401 -IP Security Architecture, section 8.6 described an MLS security gateway using IPsec as:
"a security gateway acting as an outbound proxy, creating SAs for MLS
systems that originate packets forwarded by the gateway. These MLS systems may explicitly label the packets to be forwarded, or the whole originating network may have sensitivity characteristics associated with it. The security gateway MUST create and use appropriate SAs for AH, ESP or both, to protect such traffic it forwards.Similarly such a gateway SHOULD accept and process inbound AH and/or ESP packets and forward appropriately, using explicit packet labeling, or relying on the sensitivity characteristics of the destination network."
Quoted 5 lines
All mention of MLS networking as in rfc 2401 was left out in rfc 4301. So I want to reintroduce it as MAC networking instead.
Do we want to consider labeled ipsec for security gateways in MAC networking? There would be 2 cases that I can think of.
Yes.
Quoted 15 lines
1. machines behind the security gateway that explicitly label the packets (CIPSO). This is stated above.
In this case above text is still applicable.
2. The whole originating network has a security context associated with it. In this case, packets from machines behind the security gateway are not explicitly labeled. These machines send their packets to security security gateway to be forwarded. This incoming interface of the security gateway is labeled. All packets arriving on it (from machines behind the gateway) would be marked with this label. And that would be the label used to negotiate and create the SAs for the packets originating from behind the gateway.
Quoted 1 line
Is this acceptable MAC networking for security gateways?
There are likely other scenarios as well, e.g. using the source IP as a selector, etc.
There is also the issue of outer vs. inner label in the Sun labeled IPSEC design, but I'm not certain we want to support that.
Signature · 8 lines
Stephen Smalley National Security Agency -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Quoted 5 lines · Stephen Smalley
I don't think we want to support taking the label from the SPD entry; or if we did, I think it would be a separate label from the normal SPD label - one specifically dedicated to being applied to SAs.
Ok, yes, makes sense because SPD entry's label is for a different purpose.
Quoted 43 lines
Quoted 20 lines
I have another question:
2. Security Gateways in MAC networking.
In obsoleted rfc 2401 -IP Security Architecture, section 8.6 described an MLS security gateway using IPsec as:
"a security gateway acting as an outbound proxy, creating SAs for MLS
systems that originate packets forwarded by the gateway. These MLS systems may explicitly label the packets to be forwarded, or the whole originating network may have sensitivity characteristics associated with it. The security gateway MUST create and use appropriate SAs for AH, ESP or both, to protect such traffic it forwards.Similarly such a gateway SHOULD accept and process inbound AH and/or ESP packets and forward appropriately, using explicit packet labeling, or relying on the sensitivity characteristics of the destination network."
Quoted 5 lines
All mention of MLS networking as in rfc 2401 was left out in rfc 4301. So I want to reintroduce it as MAC networking instead.
Do we want to consider labeled ipsec for security gateways in MAC networking? There would be 2 cases that I can think of.
Yes.
Quoted 15 lines
1. machines behind the security gateway that explicitly label the packets (CIPSO). This is stated above.
In this case above text is still applicable.
2. The whole originating network has a security context associated with it. In this case, packets from machines behind the security gateway are not explicitly labeled. These machines send their packets to security security gateway to be forwarded. This incoming interface of the security gateway is labeled. All packets arriving on it (from machines behind the gateway) would be marked with this label. And that would be the label used to negotiate and create the SAs for the packets originating from behind the gateway.
Quoted 8 lines
Quoted 1 line
Is this acceptable MAC networking for security gateways?
There are likely other scenarios as well, e.g. using the source IP as a selector, etc.
There is also the issue of outer vs. inner label in the Sun labeled IPSEC design, but I'm not certain we want to support that.
I am not familiar with outer vs inner label in the Sun's design. I will look it up so I can better understand.
Thanks!!
regards,
Joy
--
This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Quoted 20 lines · Joy Latten
I am finishing up the internet-drafts for labeled ipsec. The ipsec RFCs have been updated and I have a question about how one of the new features in one of the updated rfcs should work with labeled ipsec or MAC networking in general.
1. rfc 4301 - IP Security Architecture introduces and describes a Populate From Packet (PFP) flag on page 23.
When creating a new SA, the PFP flag is used to determine whether the value for the selector of the new SA will come from the packet that triggered the SA's creation or from the SPD entry. For example, the source address is a selector. An outbound packet finds an SPD entry, but no SA, so must create an SA. Currently, we take packet's source address and use this as source address when negotiating and creating new SA.
However, according to rfc 4301, PFP flag can be set and then used to decide whether newly created SA's source address selector might come from the packet or from the SPD entry.
Quoted 8 lines
My concern is that security context is described in draft as a selector, thus I need to consider PFP flag. Do we want PFP-flag capability for security context selector? For example, in current selinux policy, ipsec_spd_t:s0 is default SPD entry label. Let's say sshd triggers SA creation with sshd_t:s0. Currently, new SA will be created with sshd_t:s0. However, with PFP capability, new SA being created could have sshd_t:s0 or ipsec_spd_t:s0 depending on what PFP-flag is set to?
I agree with Stephen, I don't think we want to ever use a SPD security label as the SA's security label. The security label of a SPD entry is used to signify a specific IPsec configuration (endpoints, transformations, ciphers, hmacs, etc.) where the security label of a SA is used to signify the sending subject's security label (SSH versus Firefox, SECRET versus TOP_SECRET, etc.). This separation is really the one nice thing I see about labeled IPsec because it allows you to match a sending domain with a very specific IPsec configuration through SELinux policy which allows you to make statements like all Firefox traffic will be protected with ESP using AES-128 where all SSH traffic will be protected with AH using SHA1.
Quoted 18 lines
2. Security Gateways in MAC networking.
In obsoleted rfc 2401 -IP Security Architecture, section 8.6 described an MLS security gateway using IPsec as:
"a security gateway acting as an outbound proxy, creating SAs for
MLS systems that originate packets forwarded by the gateway. These MLS systems may explicitly label the packets to be forwarded, or the whole originating network may have sensitivity characteristics associated with it. The security gateway MUST create and use appropriate SAs for AH, ESP or both, to protect such traffic it forwards.Similarly such a gateway SHOULD accept and process inbound AH
and/or ESP packets and forward appropriately, using explicit packet labeling, or relying on the sensitivity characteristics of the destination network."
Quoted 5 lines
All mention of MLS networking as in rfc 2401 was left out in rfc 4301. So I want to reintroduce it as MAC networking instead.
Do we want to consider labeled ipsec for security gateways in MAC networking?
Most definitely yes.
Quoted 14 lines
1. machines behind the security gateway that explicitly label the packets (CIPSO). This is stated above.
In this case above text is still applicable.
2. The whole originating network has a security context associated with it. In this case, packets from machines behind the security gateway are not explicitly labeled. These machines send their packets to security security gateway to be forwarded. This incoming interface of the security gateway is labeled. All packets arriving on it (from machines behind the gateway) would be marked with this label. And that would be the label used to negotiate and create the SAs for the packets originating from behind the gateway.
Quoted 1 line
Is this acceptable MAC networking for security gateways?
I think so, I know of several users who have multiple single label networks connected to a multiple label network via a security gateway/guard that handles the labeling/routing/multiplexing. Just in cased you missed the discussion earlier this year, check the SELinux archives for the discussions around static/fallback labels (included for the first time in 2.6.25). The static/fallback labels can be used to specify per-host, per-network, or per-interface security labels for unlabeled traffic.
As far as James' comments about assigning network peer security labels with greater granularity than a single host, we discussed this quite a bit in the static/fallback label threads; while it makes sense for things like SECMARK, it makes less sense when you are talking about unlabeled peers. That said, I don't think a RFC specification needs to restrict implementation from assigning network peer labels however they see fit; I'm just not sure we would end up doing anything finer grained than a single address.
Hopefully you will send your early drafts to this list for review? :)
Signature · 7 lines
paul moore linux @ hp -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Hi Paul!
Quoted 12 lines · Paul Moore
I agree with Stephen, I don't think we want to ever use a SPD security label as the SA's security label. The security label of a SPD entry is used to signify a specific IPsec configuration (endpoints, transformations, ciphers, hmacs, etc.) where the security label of a SA is used to signify the sending subject's security label (SSH versus Firefox, SECRET versus
TOP_SECRET, etc.). This separation is really the one nice thing I see about labeled IPsec because it allows you to match a sending domain with a very specific IPsec configuration through SELinux policy which allows you to make statements like all Firefox traffic will be protected with ESP using AES-128 where all SSH traffic will be protected with AH using SHA1.
Yes, I agree. The separation is important. So, I will document PFP flag is not applicable to select security context of SA.
Quoted 42 lines
Quoted 18 lines
2. Security Gateways in MAC networking.
In obsoleted rfc 2401 -IP Security Architecture, section 8.6 described an MLS security gateway using IPsec as:
"a security gateway acting as an outbound proxy, creating SAs for
MLS systems that originate packets forwarded by the gateway. These MLS systems may explicitly label the packets to be forwarded, or the whole originating network may have sensitivity characteristics associated with it. The security gateway MUST create and use appropriate SAs for AH, ESP or both, to protect such traffic it forwards.Similarly such a gateway SHOULD accept and process inbound AH
and/or ESP packets and forward appropriately, using explicit packet labeling, or relying on the sensitivity characteristics of the destination network."Quoted 5 lines
All mention of MLS networking as in rfc 2401 was left out in rfc 4301. So I want to reintroduce it as MAC networking instead.
Do we want to consider labeled ipsec for security gateways in MAC networking?
Most definitely yes.
Quoted 14 lines
1. machines behind the security gateway that explicitly label the packets (CIPSO). This is stated above.
In this case above text is still applicable.
2. The whole originating network has a security context associated with it. In this case, packets from machines behind the security gateway are not explicitly labeled. These machines send their packets to security security gateway to be forwarded. This incoming interface of the security gateway is labeled. All packets arriving on it (from machines behind the gateway) would be marked with this label. And that would be the label used to negotiate and create the SAs for the packets originating from behind the gateway.
Quoted 1 line
Is this acceptable MAC networking for security gateways?
Quoted 9 lines
I think so, I know of several users who have multiple single label networks connected to a multiple label network via a security gateway/guard that handles the labeling/routing/multiplexing. Just in cased you missed the discussion earlier this year, check the SELinux archives for the discussions around static/fallback labels (included for the first time in 2.6.25). The static/fallback labels can be used to specify per-host, per-network, or per-interface security labels for unlabeled traffic.
Thanks for the pointer, I definitely will take a look.
Quoted 11 lines
As far as James' comments about assigning network peer security labels with greater granularity than a single host, we discussed this quite a bit in the static/fallback label threads; while it makes sense for things like SECMARK, it makes less sense when you are talking about unlabeled peers. That said, I don't think a RFC specification needs to restrict implementation from assigning network peer labels however they see fit; I'm just not sure we would end up doing anything finer grained than a single address.
Hopefully you will send your early drafts to this list for review? :)
Sure!
regards,
Joy
--
This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.