Search Issue Tracker

Fixed

Fixed in 2021.3.9f1, 2022.1.16f1, 2022.2.0b8, 2023.1.0a6

Votes

1

Found in

2021.3.6f1

2022.1.9f1

2022.2.0b1

2023.1.0a3

Issue ID

UUM-8801

Regression

Yes

[IL2CPP] NotSupportedException is thrown when using Ping from System.Net.NetworkInformation

--

-

How to reproduce:
1. Open the attached project ("IN-9999_repro.zip")
2. Build And Run

Reproducible with: 2021.2.0a18, 2021.3.6f1, 2022.1.9f1, 2022.2.0b1, 2023.1.0a3
Not reproducible with: 2020.3.37f1, 2021.2.0a17

Reproducible on:
iPhone 13 mini (iOS 15)
macOS 12.1 (Intel)

NotSupportedException: ../mscorlib/System.Security.Principal/WindowsIdentity.cpp(19) : Unsupported internal call for IL2CPP:WindowsIdentity::GetCurrentToken - "This icall is not supported by il2cpp."
  at System.Security.Principal.WindowsIdentity.GetCurrent () [0x00000] in <00000000000000000000000000000000>:0 
  at System.Net.NetworkInformation.Ping..cctor () [0x00000] in <00000000000000000000000000000000>:0 
  at PingExample..ctor () [0x00000] in <00000000000000000000000000000000>:0 
Rethrow as TypeInitializationException: The type initializer for 'System.Net.NetworkInformation.Ping' threw an exception.
  at PingExample..ctor () [0x00000] in <00000000000000000000000000000000>:0 

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.