Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Troubleshooting custom applications that consume the MIP SDK begins with inspecting MIP logs. You configure the MIP log location when you create MipContext, and you can query logs by using the *.miplog file extension.
Microsoft apps and samples store MIP logs at application path\APP_DATA\mip_data.
Mask sensitive data in MIP logs
Logs in the MIP SDK don't mask sensitive content that might personally identify a customer unless you configure masking.
Common sensitive data in MIP SDK logs:
- Email names
- File names
- Label names
- IP addresses
- MAC addresses
To mask sensitive content in all *.miplog files generated by the MIP SDK, create a new field in the JSON configuration file or configure MipConfiguration.
Configuration file
Use configuration files to configure custom settings in the MIP SDK on all supported platforms. To mask PII in MIP log files, use the following method.
- Create a custom-settings configuration file named
mip_config.jsonthat the MIP SDK can access, and store the file in the following MipConfiguration path.
mipConfiguration->GetPath()/mip
- Add a new field to
mip_config.jsonto set theAllowPiifield to false.
{"MipLogger":{"MaxLogFilesSizeMb":40,"MaxLogFileCount":10,"AllowPii":false}}
After you configure this setting, the MIP SDK masks sensitive content in all new MIP logs.
Configure in MipConfiguration
To mask PII in MIP log files with MipConfiguration, create a new MipConfiguration object that contains the new custom setting values to pass into MipContext.
This method is supported for C++ and C# only. If you use the C API or Java wrappers, create a configuration file instead.
auto mipConfiguration = make_shared<mip::MipConfiguration>(appInfo, "mip_data", mip::LogLevel::Trace, false, mip::CacheStorageType::OnDisk);
auto loggerConfiguration = make_shared<mip::LoggerConfiguration>();
loggerConfiguration->isPiiAllowed = false;
mipConfiguration->SetLoggerConfiguration(loggerConfiguration);
auto mipContext = MipContext::Create(mipConfiguration);
MipConfiguration mipConfiguration = new MipConfiguration(appInfo, "mip_data", LogLevel.Trace, false, CacheStorageType.OnDiskEncrypted);
mipConfiguration.LoggerConfigurationOverride = new LoggerConfiguration(10, 40, false);
var mipContext = MIP.CreateMipContext(mipConfiguration);