如何解决MsalException:应用程序未配置为多租户应用程序 Android?
我的Android应用正在本指南azure上使用MSAL
MsalException:应用程序未配置为多租户应用程序。在'10 / 15/2018'之后创建的此类应用程序不支持使用/ common端点。使用特定于租户的端点或将应用程序配置为多租户。
@H_502_7@
现在,我不想将应用程序配置为多租户。所以我有了第二种选择
使用特定于租户的端点
@H_502_7@
根据我所看到的,我需要将其添加到现在看起来像这样的msal.config文件中:
{ "client_id" : "my cli id","redirect_uri" : "my red uri","broker_redirect_uri_registered": true,"account_mode": "MULTIPLE","authorities" : [ { "type": "AAD","audience": { "type": "AzureADandPersonalMicrosoftAccount" } } ] }
现在这没有任何效果,我也理解我需要将带有Tennant ID的端点的URL放在某处,并且它将/ common作为默认值,
任何人都对如何做到这一点有任何想法或例子吗?
谢谢
解决方法
在“受众群体”中,将“类型”更改为“ AzureADMyOrg”,然后在其后添加“ tenant_id”。
def custom_loss(tensor1,tensor2): # convert tensors to PIL image,doing calculation,we have output = 0.123 grad = (tensor1 + tensor2).sum() loss = grad - grad + output return loss
声明:本站所有文章,如无特殊说明或标注,均为本站原创发布。任何个人或组织,在未征得本站同意时,禁止复制、盗用、采集、发布本站内容到任何网站、书籍等各类媒体平台。如若本站内容侵犯了原著者的合法权益,可联系我们进行处理。