File tree 2 files changed +9
-1
lines changed
2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -548,7 +548,9 @@ protected void WriteSurvey()
548
548
549
549
private void SanitizeOutput ( object sendToPipeline )
550
550
{
551
- if ( OutputSanitizer ? . RequireSecretsDetection == true )
551
+ if ( OutputSanitizer != null && OutputSanitizer . RequireSecretsDetection
552
+ && ! OutputSanitizer . IgnoredModules . Contains ( MyInvocation ? . MyCommand ? . ModuleName )
553
+ && ! OutputSanitizer . IgnoredCmdlets . Contains ( MyInvocation ? . MyCommand ? . Name ) )
552
554
{
553
555
OutputSanitizer . Sanitize ( sendToPipeline , out var telemetry ) ;
554
556
_qosEvent ? . SanitizerInfo . Combine ( telemetry ) ;
Original file line number Diff line number Diff line change 12
12
// limitations under the License.
13
13
// ----------------------------------------------------------------------------------
14
14
15
+ using System . Collections . Generic ;
16
+
15
17
namespace Microsoft . WindowsAzure . Commands . Common . Sanitizer
16
18
{
17
19
public interface IOutputSanitizer
18
20
{
19
21
bool RequireSecretsDetection { get ; }
20
22
23
+ IEnumerable < string > IgnoredModules { get ; }
24
+
25
+ IEnumerable < string > IgnoredCmdlets { get ; }
26
+
21
27
void Sanitize ( object sanitizingObject , out SanitizerTelemetry telemetryData ) ;
22
28
}
23
29
}
You can’t perform that action at this time.
0 commit comments