Xamarin.Forms 中的通用链接
我正在 Xamarin.Forms 应用程序中实现一个支付提供商,它提供了一个在系统浏览器中打开的结帐 URL。结帐完成后,必须将应用程序带到前台才能继续该过程。
它似乎部分工作,因为以下方法被触发:
- .NET 标准项目
- AppDelegate.WillContinueUserActivity()中的
App.OnAppLinkRequestReceived()
iOS 平台项目中的 > 和AppDelegate.ContinueUserActivity()
但是,应用程序不会进入前台。例如,当我自己从笔记应用程序打开网址时,该应用程序被带到前台。
我的问题:为什么应用程序没有进入前台,或者我如何获得有关为什么没有发生这种情况的更多信息?我需要在触发方法之一中执行一些代码吗?
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>
<key>keychain-access-groups</key>
<array>
<string>$(AppIdentifierPrefix)com.microsoft.adalcache</string>
</array>
<key>com.apple.developer.associated-domains</key>
<array>
<string>applinks:example.com?mode=developer</string>
</array>
</dict>
</plist>
apple-app-site-association
{
"applinks": {
"apps": [],
"details": [
{
"appID": "ABCD1234.com.example.testapp",
"paths": [ "*" ]
},
{
"appID": "com.example.testapp",
"paths": [ "*" ]
}
]
}
}
托管于:
- https://example.com/apple-app-site-association
- https://example.com/.wk/apple-app-site-association
- https://example.com/.well-known/apple-app-site-association
带有标头 content-type: application/json
其他项目信息
- Xamarin.Forms版本:
5.0.0.2337
- .NET 标准版本:
2.1
- 重定向网址:
https://example.com
测试
- iPhone SE(第 2 代)iOS 15.2(虚拟设备)
- iPhone 6S iOS 14.7.1(物理设备)
设置 >开发商>这些设备上启用了关联域开发
设备日志(按“swcd”过滤)
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> finished successfully
Feb 21 12:33:47 Daans-iPhone Notice 137 symptomsd(SymptomEvaluator) defusing ticker tickerFatal having seen progress by flow for swcd, rxbytes 5599 duration 1.222 seconds started at time: Mon Feb 21 12:33:46 2022
Feb 21 12:33:47 Daans-iPhone Notice 137 symptomsd(SymptomEvaluator) Data Usage for swcd - WiFi in/out: 443927/123845, WiFi delta_in/delta_out: 5599/1739, Cell in/out: 0/0, Cell delta_in/delta_out: 0/0, RNF: 0, subscriber tag: 0
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libusrtcp.dylib) tcp_input [C9.1:3] flags=[F.] seq=2215396769, ack=738694451, win=68 state=FIN_WAIT_1 rcv_nxt=2215396769, snd_una=738694450
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libusrtcp.dylib) tcp_output [C9.1:3] flags=[F.] seq=738694450, ack=2215396769, win=8192 state=FIN_WAIT_1 rcv_nxt=2215396769, snd_una=738694426
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: done
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) nw_connection_report_state_with_handler_on_nw_queue [C9] reporting state cancelled
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) nw_flow_disconnected [C9.1 IPv4#bd93adec:443 cancelled channel-flow ((null))] Output protocol disconnected
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libusrtcp.dylib) nw_protocol_tcp_log_summary [C9.1:3]
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 F664787C-9E7E-433F-8047-A337C6323B5E Hostname#9bd97782:443 tcp, url hash: 52910e2d, tls] cancelled
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 F664787C-9E7E-433F-8047-A337C6323B5E Hostname#9bd97782:443 tcp, url hash: 52910e2d, tls] cancel
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: cleaning up
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> summary for task success {transaction_duration_ms=261, response_status=200, connection=9, protocol="http/1.1", domain_lookup_duration_ms=4, connect_duration_ms=56, secure_connection_duration_ms=42, request_start_ms=66, request_duration_ms=0, response_start_ms=259, response_duration_ms=1, request_bytes=242, response_bytes=1189, cache_hit=0}
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> done using Connection 9
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> response ended
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> received response, status 200 content C
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> sent request, body N 0
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: received viability advisory(Y)
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> now using Connection 9
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: ready C(N) E(N)
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: TLS handshake complete
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9.1 IPv4#bd93adec:443 ready channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] event: flow:changed_viability @0.063s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: connected successfully
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 Hostname#9bd97782:443 ready resolver (satisfied (Path is satisfied), interface: en0, ipv4, dns)] event: flow:changed_viability @0.063s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 Hostname#9bd97782:443 ready resolver (satisfied (Path is satisfied), interface: en0, ipv4, dns)] event: flow:finish_connect @0.063s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) nw_connection_report_state_with_handler_on_nw_queue [C9] reporting state ready
Feb 21 12:33:46 Daans-iPhone Error 273 swcd(libnetwork.dylib) nw_endpoint_handler_set_adaptive_write_handler [C9.1 IPv4#bd93adec:443 ready channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] unregister notification for write_timeout failed
Feb 21 12:33:46 Daans-iPhone Error 273 swcd(libnetwork.dylib) nw_endpoint_handler_set_adaptive_read_handler [C9.1 IPv4#bd93adec:443 ready channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] unregister notification for read_timeout failed
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9.1 IPv4#bd93adec:443 ready channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] event: flow:finish_connect @0.062s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) nw_flow_connected [C9.1 IPv4#bd93adec:443 in_progress channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] Output protocol connected
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) nw_protocol_boringssl_signal_connected(737) [C9.1:2][0x104a2d6d0] TLS connected [version(0x0304) ciphersuite(TLS_AES_128_GCM_SHA256) group(0x001d) signature_alg(0x0403) alpn(http/1.1) resumed(0) offered_ticket(0) false_started(0) ocsp_received(1) sct_received(0) connect_time(42ms) flight_time(23ms) rtt(11ms) write_stalls(0) read_stalls(6)]
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1863) [C9.1:2][0x104a2d6d0] Client handshake done
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS client done
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS client finish_client_handshake
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client done
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client complete_second_flight
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client send_client_certificate
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client send_client_encrypted_extensions
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client send_end_of_early_data
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client read_server_finished
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_certificate_verify_callback(1646) [C9.1:2][0x104a2d6d0] Certificate verification result: OK
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: TLS Trust result 0
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_evaluate_trust_async_external_block_invoke_3(1488) [C9.1:2][0x104a2d6d0] Returning from external verify block with result: true
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> auth completion disp=0 cred=0x104b24130
Feb 21 12:33:46 Daans-iPhone Notice 132 mDNSResponder [R929] getaddrinfo stop -- hostname: <mask.hash: 'bMVtjUtxYcdCKEOF9CD48Q=='>, client pid: 273 (swcd)
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: asked to evaluate TLS Trust
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_evaluate_trust_async_external(1532) [C9.1:2][0x104a2d6d0] Asyncing for external verify block
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_evaluate_trust_async(1547) [C9.1:2][0x104a2d6d0] Performing external trust evaluation
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client read_server_certificate_verify
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client read_server_certificate
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client read_certificate_request
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client read_encrypted_extensions
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client read_server_hello
Feb 21 12:33:46 Daans-iPhone Notice 137 symptomsd(SymptomEvaluator) Data Usage for swcd - WiFi in/out: 438328/122106, WiFi delta_in/delta_out: 90/58, Cell in/out: 0/0, Cell delta_in/delta_out: 0/0, RNF: 0, subscriber tag: 0
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client read_hello_retry_request
Feb 21 12:33:46 Daans-iPhone Notice 137 symptomsd(SymptomEvaluator) Data Usage for swcd - WiFi in/out: 438238/122048, WiFi delta_in/delta_out: 137/58, Cell in/out: 0/0, Cell delta_in/delta_out: 0/0, RNF: 0, subscriber tag: 0
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS client read_server_hello
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS client enter_early_data
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1858) [C9.1:2][0x104a2d6d0] Client handshake started
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_session_apply_protocol_options_for_transport_block_invoke(1685) [C9.1:2][0x104a2d6d0] TLS configured [min_version(0x0301) max_version(0x0304) name(<private>) tickets(false) false_start(false) enforce_ev(false) enforce_ats(false)]
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 Hostname#9bd97782:443 in_progress resolver (satisfied (Path is satisfied), interface: en0, ipv4, dns)] event: flow:finish_transport @0.019s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9.1 IPv4#bd93adec:443 in_progress channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] event: flow:finish_transport @0.019s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) nw_flow_connected [C9.1 IPv4#bd93adec:443 in_progress channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] Transport protocol connected
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libusrtcp.dylib) tcp_input [C9.1:3] flags=[S.E] seq=2215392168, ack=738693581, win=65535 state=SYN_SENT rcv_nxt=0, snd_una=738693580
Feb 21 12:33:46 Daans-iPhone Notice 137 symptomsd(SymptomEvaluator) Data Usage for swcd - WiFi in/out: 438101/121990, WiFi delta_in/delta_out: 0/90, Cell in/out: 0/0, Cell delta_in/delta_out: 0/0, RNF: 0, subscriber tag: 0
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libusrtcp.dylib) tcp_output [C9.1:3] flags=[SEC] seq=738693580, ack=0, win=65535 state=SYN_SENT rcv_nxt=0, snd_una=738693580
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9.1 IPv4#bd93adec:443 in_progress channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] event: flow:start_connect @0.006s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9.1 IPv4#bd93adec:443 in_progress channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] event: flow:receive_nexus @0.005s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9.1 IPv4#bd93adec:443 in_progress channel-flow (satisfied (Path is satisfied), interface: en0, ipv4, dns)] event: flow:start_nexus @0.004s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9.1 IPv4#bd93adec:443 waiting path (satisfied (Path is satisfied), interface: en0, ipv4, dns)] event: path:satisfied @0.004s, uuid: ADA1500A-E94B-4A30-9770-8933C203760E
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9.1 IPv4#bd93adec:443 initial path ((null))] event: path:start @0.004s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 Hostname#9bd97782:443 in_progress resolver (satisfied (Path is satisfied), interface: en0, ipv4, dns)] event: resolver:receive_dns @0.004s
Feb 21 12:33:46 Daans-iPhone Notice 132 mDNSResponder [R929] getaddrinfo start -- flags: 0xC000D000, ifindex: 0, protocols: 0, hostname: <mask.hash: 'bMVtjUtxYcdCKEOF9CD48Q=='>, options: {}, client pid: 273 (swcd)
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> setting up Connection 9
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) nw_connection_report_state_with_handler_on_nw_queue [C9] reporting state preparing
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 Hostname#9bd97782:443 in_progress resolver (satisfied (Path is satisfied), interface: en0, ipv4, dns)] event: resolver:start_dns @0.000s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 Hostname#9bd97782:443 waiting path (satisfied (Path is satisfied), interface: en0, ipv4, dns)] event: path:satisfied @0.000s, uuid: 678EC73A-48CF-433A-A4D0-3F602D2BC14D
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 Hostname#9bd97782:443 initial path ((null))] event: path:start @0.000s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 F664787C-9E7E-433F-8047-A337C6323B5E Hostname#9bd97782:443 tcp, url hash: 52910e2d, tls, context: com.apple.CFNetwork.NSURLSession.{6865B792-1371-4FED-954B-A67D1573484C}{(null)}{Y}{2}, proc: AD122783-7C34-325A-9752-A491555C782B] start
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: starting, TC(0x0)
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: enabling TLS
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> {strength 0, tls 4, ct 0, sub 0, sig 1, ciphers 0, bundle 1, builtin 0}
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd Already downloading data for domain wr\M-b\M^@\M-&.com?mode=developer, so skipping a second download (non-discretionary)
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) [Telemetry]: Activity <nw_activity 12:2 [65103058-3EC1-4B6D-A400-5F050677DE41] (reporting strategy default)> on Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> was not selected for reporting
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> resuming, timeouts(60.0, 604800.0) QOS(0x15) Voucher (null)
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd Beginning data task AASA-F1D70EDA-26AF-4E71-9456-D9F0094E1614 { domain: wr\M-b\M^@\M-&.com?mode=developer, bytes: 0, route: .wk }
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd Developer mode enabled: YES
Feb 21 12:33:46 Daans-iPhone Error 273 swcd Error getting enterprise-managed associated domains data. If this device is not enterprise-managed, this is normal: Error Domain=SWCErrorDomain Code=1701 "Failed to get associated domain data from ManagedConfiguration framework." UserInfo={NSDebugDescription=Failed to get associated domain data from ManagedConfiguration framework., Line=298, Function=<private>}
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd LS database generation has changed 1425 to 1428. Synchronizing SWC database to it.
I'm implementing a payment provider in my Xamarin.Forms app, which provides a checkout url that is opened in the system browser. After the checkout is completed, the app must be brought to the foreground to continue the process.
It seems to be working partially, because the following methods are fired:
App.OnAppLinkRequestReceived()
in the .NET standard projectAppDelegate.WillContinueUserActivity()
andAppDelegate.ContinueUserActivity()
in the iOS platform project
However, the app is not brought to the foreground. When I open the url myself from the notes app for example, the app is brought to the foreground.
My questions: Why is the application not brought to the foreground, or how can I get more information about why this is not happening? Do I need to execute some code in one of the triggered methods?
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>
<key>keychain-access-groups</key>
<array>
<string>$(AppIdentifierPrefix)com.microsoft.adalcache</string>
</array>
<key>com.apple.developer.associated-domains</key>
<array>
<string>applinks:example.com?mode=developer</string>
</array>
</dict>
</plist>
apple-app-site-association
{
"applinks": {
"apps": [],
"details": [
{
"appID": "ABCD1234.com.example.testapp",
"paths": [ "*" ]
},
{
"appID": "com.example.testapp",
"paths": [ "*" ]
}
]
}
}
Hosted on:
- https://example.com/apple-app-site-association
- https://example.com/.wk/apple-app-site-association
- https://example.com/.well-known/apple-app-site-association
With header content-type: application/json
Other project information
- Xamarin.Forms version:
5.0.0.2337
- .NET Standard version:
2.1
- Redirect url:
https://example.com
Tested on
- iPhone SE (2nd gen) iOS 15.2 (virtual device)
- iPhone 6S iOS 14.7.1 (physical device)
Settings > Developer > Associated Domains Development
is enabled on these devices
Device log (filtered on 'swcd')
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> finished successfully
Feb 21 12:33:47 Daans-iPhone Notice 137 symptomsd(SymptomEvaluator) defusing ticker tickerFatal having seen progress by flow for swcd, rxbytes 5599 duration 1.222 seconds started at time: Mon Feb 21 12:33:46 2022
Feb 21 12:33:47 Daans-iPhone Notice 137 symptomsd(SymptomEvaluator) Data Usage for swcd - WiFi in/out: 443927/123845, WiFi delta_in/delta_out: 5599/1739, Cell in/out: 0/0, Cell delta_in/delta_out: 0/0, RNF: 0, subscriber tag: 0
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libusrtcp.dylib) tcp_input [C9.1:3] flags=[F.] seq=2215396769, ack=738694451, win=68 state=FIN_WAIT_1 rcv_nxt=2215396769, snd_una=738694450
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libusrtcp.dylib) tcp_output [C9.1:3] flags=[F.] seq=738694450, ack=2215396769, win=8192 state=FIN_WAIT_1 rcv_nxt=2215396769, snd_una=738694426
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: done
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) nw_connection_report_state_with_handler_on_nw_queue [C9] reporting state cancelled
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) nw_flow_disconnected [C9.1 IPv4#bd93adec:443 cancelled channel-flow ((null))] Output protocol disconnected
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libusrtcp.dylib) nw_protocol_tcp_log_summary [C9.1:3]
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 F664787C-9E7E-433F-8047-A337C6323B5E Hostname#9bd97782:443 tcp, url hash: 52910e2d, tls] cancelled
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 F664787C-9E7E-433F-8047-A337C6323B5E Hostname#9bd97782:443 tcp, url hash: 52910e2d, tls] cancel
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: cleaning up
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> summary for task success {transaction_duration_ms=261, response_status=200, connection=9, protocol="http/1.1", domain_lookup_duration_ms=4, connect_duration_ms=56, secure_connection_duration_ms=42, request_start_ms=66, request_duration_ms=0, response_start_ms=259, response_duration_ms=1, request_bytes=242, response_bytes=1189, cache_hit=0}
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> done using Connection 9
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> response ended
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> received response, status 200 content C
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> sent request, body N 0
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: received viability advisory(Y)
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> now using Connection 9
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: ready C(N) E(N)
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: TLS handshake complete
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9.1 IPv4#bd93adec:443 ready channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] event: flow:changed_viability @0.063s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: connected successfully
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 Hostname#9bd97782:443 ready resolver (satisfied (Path is satisfied), interface: en0, ipv4, dns)] event: flow:changed_viability @0.063s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 Hostname#9bd97782:443 ready resolver (satisfied (Path is satisfied), interface: en0, ipv4, dns)] event: flow:finish_connect @0.063s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) nw_connection_report_state_with_handler_on_nw_queue [C9] reporting state ready
Feb 21 12:33:46 Daans-iPhone Error 273 swcd(libnetwork.dylib) nw_endpoint_handler_set_adaptive_write_handler [C9.1 IPv4#bd93adec:443 ready channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] unregister notification for write_timeout failed
Feb 21 12:33:46 Daans-iPhone Error 273 swcd(libnetwork.dylib) nw_endpoint_handler_set_adaptive_read_handler [C9.1 IPv4#bd93adec:443 ready channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] unregister notification for read_timeout failed
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9.1 IPv4#bd93adec:443 ready channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] event: flow:finish_connect @0.062s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) nw_flow_connected [C9.1 IPv4#bd93adec:443 in_progress channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] Output protocol connected
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) nw_protocol_boringssl_signal_connected(737) [C9.1:2][0x104a2d6d0] TLS connected [version(0x0304) ciphersuite(TLS_AES_128_GCM_SHA256) group(0x001d) signature_alg(0x0403) alpn(http/1.1) resumed(0) offered_ticket(0) false_started(0) ocsp_received(1) sct_received(0) connect_time(42ms) flight_time(23ms) rtt(11ms) write_stalls(0) read_stalls(6)]
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1863) [C9.1:2][0x104a2d6d0] Client handshake done
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS client done
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS client finish_client_handshake
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client done
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client complete_second_flight
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client send_client_certificate
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client send_client_encrypted_extensions
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client send_end_of_early_data
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client read_server_finished
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_certificate_verify_callback(1646) [C9.1:2][0x104a2d6d0] Certificate verification result: OK
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: TLS Trust result 0
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_evaluate_trust_async_external_block_invoke_3(1488) [C9.1:2][0x104a2d6d0] Returning from external verify block with result: true
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> auth completion disp=0 cred=0x104b24130
Feb 21 12:33:46 Daans-iPhone Notice 132 mDNSResponder [R929] getaddrinfo stop -- hostname: <mask.hash: 'bMVtjUtxYcdCKEOF9CD48Q=='>, client pid: 273 (swcd)
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: asked to evaluate TLS Trust
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_evaluate_trust_async_external(1532) [C9.1:2][0x104a2d6d0] Asyncing for external verify block
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_evaluate_trust_async(1547) [C9.1:2][0x104a2d6d0] Performing external trust evaluation
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client read_server_certificate_verify
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client read_server_certificate
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client read_certificate_request
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client read_encrypted_extensions
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client read_server_hello
Feb 21 12:33:46 Daans-iPhone Notice 137 symptomsd(SymptomEvaluator) Data Usage for swcd - WiFi in/out: 438328/122106, WiFi delta_in/delta_out: 90/58, Cell in/out: 0/0, Cell delta_in/delta_out: 0/0, RNF: 0, subscriber tag: 0
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS 1.3 client read_hello_retry_request
Feb 21 12:33:46 Daans-iPhone Notice 137 symptomsd(SymptomEvaluator) Data Usage for swcd - WiFi in/out: 438238/122048, WiFi delta_in/delta_out: 137/58, Cell in/out: 0/0, Cell delta_in/delta_out: 0/0, RNF: 0, subscriber tag: 0
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS client read_server_hello
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1873) [C9.1:2][0x104a2d6d0] Client handshake state: TLS client enter_early_data
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_context_info_handler(1858) [C9.1:2][0x104a2d6d0] Client handshake started
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libboringssl.dylib) boringssl_session_apply_protocol_options_for_transport_block_invoke(1685) [C9.1:2][0x104a2d6d0] TLS configured [min_version(0x0301) max_version(0x0304) name(<private>) tickets(false) false_start(false) enforce_ev(false) enforce_ats(false)]
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 Hostname#9bd97782:443 in_progress resolver (satisfied (Path is satisfied), interface: en0, ipv4, dns)] event: flow:finish_transport @0.019s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9.1 IPv4#bd93adec:443 in_progress channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] event: flow:finish_transport @0.019s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) nw_flow_connected [C9.1 IPv4#bd93adec:443 in_progress channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] Transport protocol connected
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libusrtcp.dylib) tcp_input [C9.1:3] flags=[S.E] seq=2215392168, ack=738693581, win=65535 state=SYN_SENT rcv_nxt=0, snd_una=738693580
Feb 21 12:33:46 Daans-iPhone Notice 137 symptomsd(SymptomEvaluator) Data Usage for swcd - WiFi in/out: 438101/121990, WiFi delta_in/delta_out: 0/90, Cell in/out: 0/0, Cell delta_in/delta_out: 0/0, RNF: 0, subscriber tag: 0
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libusrtcp.dylib) tcp_output [C9.1:3] flags=[SEC] seq=738693580, ack=0, win=65535 state=SYN_SENT rcv_nxt=0, snd_una=738693580
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9.1 IPv4#bd93adec:443 in_progress channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] event: flow:start_connect @0.006s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9.1 IPv4#bd93adec:443 in_progress channel-flow (satisfied (Path is satisfied), viable, interface: en0, ipv4, dns)] event: flow:receive_nexus @0.005s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9.1 IPv4#bd93adec:443 in_progress channel-flow (satisfied (Path is satisfied), interface: en0, ipv4, dns)] event: flow:start_nexus @0.004s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9.1 IPv4#bd93adec:443 waiting path (satisfied (Path is satisfied), interface: en0, ipv4, dns)] event: path:satisfied @0.004s, uuid: ADA1500A-E94B-4A30-9770-8933C203760E
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9.1 IPv4#bd93adec:443 initial path ((null))] event: path:start @0.004s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 Hostname#9bd97782:443 in_progress resolver (satisfied (Path is satisfied), interface: en0, ipv4, dns)] event: resolver:receive_dns @0.004s
Feb 21 12:33:46 Daans-iPhone Notice 132 mDNSResponder [R929] getaddrinfo start -- flags: 0xC000D000, ifindex: 0, protocols: 0, hostname: <mask.hash: 'bMVtjUtxYcdCKEOF9CD48Q=='>, options: {}, client pid: 273 (swcd)
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> setting up Connection 9
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) nw_connection_report_state_with_handler_on_nw_queue [C9] reporting state preparing
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 Hostname#9bd97782:443 in_progress resolver (satisfied (Path is satisfied), interface: en0, ipv4, dns)] event: resolver:start_dns @0.000s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 Hostname#9bd97782:443 waiting path (satisfied (Path is satisfied), interface: en0, ipv4, dns)] event: path:satisfied @0.000s, uuid: 678EC73A-48CF-433A-A4D0-3F602D2BC14D
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 Hostname#9bd97782:443 initial path ((null))] event: path:start @0.000s
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(libnetwork.dylib) [C9 F664787C-9E7E-433F-8047-A337C6323B5E Hostname#9bd97782:443 tcp, url hash: 52910e2d, tls, context: com.apple.CFNetwork.NSURLSession.{6865B792-1371-4FED-954B-A67D1573484C}{(null)}{Y}{2}, proc: AD122783-7C34-325A-9752-A491555C782B] start
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: starting, TC(0x0)
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Connection 9: enabling TLS
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> {strength 0, tls 4, ct 0, sub 0, sig 1, ciphers 0, bundle 1, builtin 0}
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd Already downloading data for domain wr\M-b\M^@\M-&.com?mode=developer, so skipping a second download (non-discretionary)
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) [Telemetry]: Activity <nw_activity 12:2 [65103058-3EC1-4B6D-A400-5F050677DE41] (reporting strategy default)> on Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> was not selected for reporting
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd(CFNetwork) Task <0D05BB27-DDE1-4979-B652-9ADEE3D8EEDB>.<1> resuming, timeouts(60.0, 604800.0) QOS(0x15) Voucher (null)
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd Beginning data task AASA-F1D70EDA-26AF-4E71-9456-D9F0094E1614 { domain: wr\M-b\M^@\M-&.com?mode=developer, bytes: 0, route: .wk }
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd Developer mode enabled: YES
Feb 21 12:33:46 Daans-iPhone Error 273 swcd Error getting enterprise-managed associated domains data. If this device is not enterprise-managed, this is normal: Error Domain=SWCErrorDomain Code=1701 "Failed to get associated domain data from ManagedConfiguration framework." UserInfo={NSDebugDescription=Failed to get associated domain data from ManagedConfiguration framework., Line=298, Function=<private>}
Feb 21 12:33:46 Daans-iPhone Notice 273 swcd LS database generation has changed 1425 to 1428. Synchronizing SWC database to it.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
事实证明,支付提供商仅支持通过系统浏览器进行外部结账。我将
await Browser.OpenAsync(checkoutUrl, BrowserLaunchMode.SystemPreferred);
更改为
await Browser.OpenAsync(checkoutUrl, BrowserLaunchMode.External);
结帐结束时的重定向流程按预期进行
Turns out the payment provider only supports external checkouts from the system browser. After I changed
await Browser.OpenAsync(checkoutUrl, BrowserLaunchMode.SystemPreferred);
to
await Browser.OpenAsync(checkoutUrl, BrowserLaunchMode.External);
The redirect at the end of the checkout process worked as expected