Parcourir la source

bypass acl policy

abhishek9686 il y a 4 mois
Parent
commit
35edcd01de
1 fichiers modifiés avec 3 ajouts et 0 suppressions
  1. 3 0
      logic/acls.go

+ 3 - 0
logic/acls.go

@@ -647,6 +647,9 @@ func IsUserAllowedToCommunicate(userName string, peer models.Node) (bool, []mode
 // IsPeerAllowed - checks if peer needs to be added to the interface
 func IsPeerAllowed(node, peer models.Node, checkDefaultPolicy bool) bool {
 	var nodeId, peerId string
+	if peer.IsFailOver && node.FailedOverBy == peer.ID {
+		return true
+	}
 	if node.IsStatic {
 		nodeId = node.StaticNode.ClientID
 		node = node.StaticNode.ConvertToStaticNode()