netbpfload: remove support for limiting selinux contexts
No need for this, as we simply only support those selinux contexts (and directories) which are available to networking. Test: TreeHugger Signed-off-by: Maciej Żenczykowski <maze@google.com> Change-Id: I35b134c57411f82514b9f7148411f83d3aee1927
This commit is contained in:
@@ -65,46 +65,34 @@ bool exists(const char* const path) {
|
||||
abort(); // can only hit this if permissions (likely selinux) are screwed up
|
||||
}
|
||||
|
||||
constexpr unsigned long long kTetheringApexDomainBitmask =
|
||||
domainToBitmask(domain::tethering) |
|
||||
domainToBitmask(domain::net_private) |
|
||||
domainToBitmask(domain::net_shared) |
|
||||
domainToBitmask(domain::netd_readonly) |
|
||||
domainToBitmask(domain::netd_shared);
|
||||
|
||||
|
||||
const android::bpf::Location locations[] = {
|
||||
// S+ Tethering mainline module (network_stack): tether offload
|
||||
{
|
||||
.dir = "/apex/com.android.tethering/etc/bpf/",
|
||||
.prefix = "tethering/",
|
||||
.allowedDomainBitmask = kTetheringApexDomainBitmask,
|
||||
},
|
||||
// T+ Tethering mainline module (shared with netd & system server)
|
||||
// netutils_wrapper (for iptables xt_bpf) has access to programs
|
||||
{
|
||||
.dir = "/apex/com.android.tethering/etc/bpf/netd_shared/",
|
||||
.prefix = "netd_shared/",
|
||||
.allowedDomainBitmask = kTetheringApexDomainBitmask,
|
||||
},
|
||||
// T+ Tethering mainline module (shared with netd & system server)
|
||||
// netutils_wrapper has no access, netd has read only access
|
||||
{
|
||||
.dir = "/apex/com.android.tethering/etc/bpf/netd_readonly/",
|
||||
.prefix = "netd_readonly/",
|
||||
.allowedDomainBitmask = kTetheringApexDomainBitmask,
|
||||
},
|
||||
// T+ Tethering mainline module (shared with system server)
|
||||
{
|
||||
.dir = "/apex/com.android.tethering/etc/bpf/net_shared/",
|
||||
.prefix = "net_shared/",
|
||||
.allowedDomainBitmask = kTetheringApexDomainBitmask,
|
||||
},
|
||||
// T+ Tethering mainline module (not shared, just network_stack)
|
||||
{
|
||||
.dir = "/apex/com.android.tethering/etc/bpf/net_private/",
|
||||
.prefix = "net_private/",
|
||||
.allowedDomainBitmask = kTetheringApexDomainBitmask,
|
||||
},
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user