mirror of
https://github.com/netbirdio/netbird.git
synced 2025-01-08 23:19:09 +01:00
Apply policy posture checks on peer
Signed-off-by: bcmmbaga <bethuelmbaga12@gmail.com>
This commit is contained in:
parent
fbce8bb511
commit
c8c25221bd
@ -1320,6 +1320,12 @@ func (a *Account) GetNetworkResourcesRoutesToSync(ctx context.Context, peerID st
|
||||
}
|
||||
|
||||
for _, policy := range resourcePolicies[resource.ID] {
|
||||
// validate the peer based on policy posture checks applied
|
||||
isValid := a.validatePostureChecksOnPeer(ctx, policy.SourcePostureChecks, peerID)
|
||||
if !isValid {
|
||||
continue
|
||||
}
|
||||
|
||||
for _, sourceGroup := range policy.SourceGroups() {
|
||||
group := a.GetGroup(sourceGroup)
|
||||
if group == nil {
|
||||
|
Loading…
Reference in New Issue
Block a user