@@ -56,20 +56,20 @@ module.exports = {
5656 vaults . data . forEach ( function ( vault ) {
5757 if ( ! vault . id ) return ;
5858
59- if ( vault &&
60- vault . publicNetworkAccess &&
59+ if ( vault &&
60+ vault . publicNetworkAccess &&
6161 vault . publicNetworkAccess . toLowerCase ( ) === 'disabled' ) {
6262 helpers . addResult ( results , 0 ,
6363 'Key Vault is protected from outside traffic' ,
6464 location , vault . id ) ;
6565 return ;
6666 }
6767
68-
68+
6969 if ( vault && vault . networkAcls ) {
7070 var networkAcls = vault . networkAcls ;
7171 var defaultAction = networkAcls . defaultAction ? networkAcls . defaultAction . toLowerCase ( ) : null ;
72-
72+
7373 if ( ! defaultAction || defaultAction === 'allow' ) {
7474 helpers . addResult ( results , 2 ,
7575 'Key Vault is open to outside traffic' ,
@@ -84,8 +84,7 @@ module.exports = {
8484
8585 for ( var rule of ipRules ) {
8686 if ( checkAllowedIps ) {
87- if ( ( rule . value === '0.0.0.0/0' || rule . value === '0.0.0.0' ) &&
88- ! allowedIps . includes ( rule . value ) ) {
87+ if ( ! allowedIps . includes ( rule . value ) ) {
8988 hasPublicAccess = true ;
9089 publicAccessFound . push ( rule . value ) ;
9190 }
@@ -116,4 +115,4 @@ module.exports = {
116115 callback ( null , results , source ) ;
117116 } ) ;
118117 }
119- } ;
118+ } ;
0 commit comments