Skip to content

Commit

Permalink
Merge pull request #1092 from kanhaiya04/Netword-policy
Browse files Browse the repository at this point in the history
forced the protocol to lowercase in AppArmorProfile
  • Loading branch information
daemon1024 authored Feb 7, 2023
2 parents e45b0ea + b5b660d commit 006641f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions KubeArmor/enforcer/appArmorProfile.go
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,9 @@ func (ae *AppArmorEnforcer) SetFileMatchPatterns(pat tp.FilePatternType, prof *P

// SetNetworkMatchProtocols Function
func (ae *AppArmorEnforcer) SetNetworkMatchProtocols(proto tp.NetworkProtocolType, prof *Profile, deny bool, head bool) {
//forcing the protocol to lowercase
proto.Protocol = strings.ToLower(proto.Protocol)

if deny == false {
prof.Network = head
}
Expand Down

0 comments on commit 006641f

Please sign in to comment.