gpt4 book ai didi

Xamarin Auth Store Keychain 在 ios10 升级后无法正常工作

转载 作者:行者123 更新时间:2023-12-03 08:13:58 24 4
gpt4 key购买 nike

我一直在使用 Xamarin.Auth ( https://components.xamarin.com/view/xamarin.auth/ ) 来存储我的凭据。

var accountStore = AccountStore.Create ();
foreach (var account in accountStore.FindAccountsForService("myAppName"))
accountStore.Delete (account, "myAppName");

AccountStore.Create().Save(acc, "myAppName");

升级到 iOS 10 后,存储凭据时出现此错误:
"Could not save account to KeyChain: -34018"

at Xamarin.Auth.KeyChainAccountStore.Save (Xamarin.Auth.Account account,System.String serviceId) [0x000b2] in <402cf9b3716845b3bdddef581cb33a3e>:0

安装的最新版本 1.2.3.1
问题似乎只在模拟器上持续存在

最佳答案

根据this thread在捆绑歌唱配置中添加一个空的权利文件就足够了:

<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|iPhoneSimulator' ">
...
<CodesignEntitlements>Entitlements.plist</CodesignEntitlements>
</PropertyGroup>

Entitlements.plist文件:

<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
</dict>
</plist>

关于Xamarin Auth Store Keychain 在 ios10 升级后无法正常工作,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39487368/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com