Browse Source

Merge branch 'release-v0.90.0' into NET-2005

Abhishek K 3 months ago
parent
commit
39214364a4
2 changed files with 3 additions and 1 deletions
  1. 2 0
      controllers/gateway.go
  2. 1 1
      logic/acls.go

+ 2 - 0
controllers/gateway.go

@@ -87,6 +87,7 @@ func createGateway(w http.ResponseWriter, r *http.Request) {
 		"on network",
 		req.RelayRequest.NetID,
 	)
+	logic.GetNodeStatus(&relayNode, false)
 	apiNode := relayNode.ConvertToAPINode()
 
 	w.WriteHeader(http.StatusOK)
@@ -200,6 +201,7 @@ func deleteGateway(w http.ResponseWriter, r *http.Request) {
 
 	}()
 
+	logic.GetNodeStatus(&node, false)
 	apiNode := node.ConvertToAPINode()
 	logger.Log(1, r.Header.Get("user"), "deleted ingress gateway", nodeid)
 	w.WriteHeader(http.StatusOK)

+ 1 - 1
logic/acls.go

@@ -1411,7 +1411,7 @@ func checkIfAnyPolicyisUniDirectional(targetNode models.Node) bool {
 		if !acl.Enabled {
 			continue
 		}
-		if acl.AllowedDirection == models.TrafficDirectionBi {
+		if acl.AllowedDirection == models.TrafficDirectionBi && acl.Proto == models.ALL && acl.ServiceType == models.Any {
 			continue
 		}
 		if acl.Proto != models.ALL || acl.ServiceType != models.Any {