AWS Sdk Not Working in IOS

I’m about at my wits end with this issue, and I just can’t wrap my head around what I am doing wrong. I have my unity project configured to use Facebook sdk as an identity provider for AWS. In the editor on my pc my login and connecting to AWS resources works perfectly, in my android build from my pc again, everything works perfectly. I have a copy of my project on my MacBook Pro and once again everything in the editor works perfectly. However, when I build my project and then compile in xccode my Facebook login is successful, but I get an exception when trying to connect to was cognate identity.

This is the error I get:

Connecting AWS
Error during aws: System.TypeInitializationException: The type initializer for ‘Amazon.CognitoIdentity.AmazonCognitoIdentityConfig’ threw an exception. —> System.TypeInitializationException: The type initializer for ‘Amazon.Util.Internal.InternalSDKUtils’ threw an exception. —> System.NullReferenceException: A null value was found where an object instance was required.
at Amazon.Runtime.Internal.Util.InternalLog4netLogger…ctor (System.Type declaringType) [0x00000] in :0
at Amazon.Runtime.Internal.Util.Logger…ctor (System.Type type) [0x00000] in :0
at Amazon.Runtime.Internal.Util.Logger.GetLogger (System.Type type) [0x00000] in :0
at Amazon.Util.Internal.InternalSDKUtils…cctor () [0x00000] in :0
at Amazon.CognitoIdentity.AmazonCognitoIdentityConfig…cctor () [0x00000] in :0
at Amazon.CognitoIdentity.AmazonCognitoIdentityClient…ctor (Amazon.Runtime.AWSCredentials credentials, Amazon.RegionEndpoint region) [0x00000] in :0
at Amazon.CognitoIdentity.CognitoAWSCredentials…ctor (System.String accountId, System.String identityPoolId, System.String unAuthRoleArn, System.String authRoleArn, Amazon.RegionEndpoint region) [0x00000] in :0
at ServerData.ConnectAWS () [0x00000] in :0
at Facebook.Unity.CallbackManager.TryCallCallback[T] (System.Object callback, IResult result) [0x00000] in :0
at Facebook.Unity.CallbackManager.CallCallback (System.Object callback, IResult result) [0x00000] in :0
at Facebook.Unity.CallbackManager.OnFacebookResponse (IInternalResult result) [0x00000] in :0
— End of inner exception stack trace —
at Amazon.CognitoIdentity.AmazonCognitoIdentityConfig…cctor () [0x00000] in :0
at Amazon.CognitoIdentity.AmazonCognitoIdentityClient…ctor (Amazon.Runtime.AWSCredentials credentials, Amazon.RegionEndpoint region) [0x00000] in :0
at Amazon.CognitoIdentity.CognitoAWSCredentials…ctor (System.String accountId, System.String identityPoolId, System.String unAuthRoleArn, System.String authRoleArn, Amazon.RegionEndpoint region) [0x00000] in :0
at ServerData.ConnectAWS () [0x00000] in :0
at Facebook.Unity.CallbackManager.TryCallCallback[T] (System.Object callback, IResult result) [0x00000] in :0
at Facebook.Unity.CallbackManager.CallCallback (System.Object callback, IResult result) [0x00000] in :0
at Facebook.Unity.CallbackManager.OnFacebookResponse (IInternalResult result) [0x00000] in :0
— End of inner exception stack trace —
at Amazon.CognitoIdentity.AmazonCognitoIdentityClient…ctor (Amazon.Runtime.AWSCredentials credentials, Amazon.RegionEndpoint region) [0x00000] in :0
at Amazon.CognitoIdentity.CognitoAWSCredentials…ctor (System.String accountId, System.String identityPoolId, System.String unAuthRoleArn, System.String authRoleArn, Amazon.RegionEndpoint region) [0x00000] in :0
at ServerData.ConnectAWS () [0x00000] in :0
at Facebook.Unity.CallbackManager.TryCallCallback[T] (System.Object callback, IResult result) [0x00000] in :0
at Facebook.Unity.CallbackManager.CallCallback (System.Object callback, IResult result) [0x00000] in :0
at Facebook.Unity.CallbackManager.OnFacebookResponse (IInternalResult result) [0x00000] in :0

Every search I can find on this issue point to saying this is a stripping issue during the build process to IOS, and that I must include a link.xml in my assets folder to combat this. I have tried every variation of suggested formats for this link.xml, and none have seemed to work. Here is my link.xml currently:

<linker>
  	<!-- if you are using AWSConfigs.HttpClient.UnityWebRequest option-->

  <assembly fullname="UnityEngine">
  	<type fullname="UnityEngine.Networking.UnityWebRequest" preserve="all" />
  	<type fullname="UnityEngine.Networking.UploadHandlerRaw" preserve="all" />
  	<type fullname="UnityEngine.Networking.UploadHandler" preserve="all" />
  	<type fullname="UnityEngine.Networking.DownloadHandler" preserve="all" />
  	<type fullname="UnityEngine.Networking.DownloadHandlerBuffer" preserve="all" />
  </assembly>
  
  <assembly fullname="mscorlib">
  	<namespace fullname="System.Security.Cryptography" preserve="all"/>
  </assembly>

  <assembly fullname="System">
  	<namespace fullname="System.Security.Cryptography" preserve="all"/>
  </assembly>

  <assembly fullname="AWSSDK.Core" preserve="all">
    <type fullname ="Amazon.*" preserve = "all" />
  	<namespace fullname="Amazon.Util.Internal.PlatformServices" preserve="all"/>
  </assembly>
  <assembly fullname="AWSSDK.CognitoIdentity" preserve="all">
  	<type fullname ="Amazon.*" preserve = "all" />
  	<namespace fullname="Amazon.Util.Internal.PlatformServices" preserve="all"/>
  </assembly>
  <assembly fullname="AWSSDK.CognitoSync" preserve="all">
    <type fullname ="Amazon.*" preserve = "all" />
    <namespace fullname="Amazon.Util.Internal.PlatformServices" preserve="all"/>
  </assembly>
  <assembly fullname="AWSSDK.IdentityManagement" preserve="all">
    <type fullname ="Amazon.*" preserve = "all" />
    <namespace fullname="Amazon.Util.Internal.PlatformServices" preserve="all"/>
  </assembly>
  <assembly fullname="AWSSDK.SecurityToken" preserve="all">
    <type fullname ="Amazon.*" preserve = "all" />
    <namespace fullname="Amazon.Util.Internal.PlatformServices" preserve="all"/>
  </assembly>
  <assembly fullname="AWSSDK.DynamoDBv2" preserve="all">
    <type fullname ="Amazon.*" preserve = "all" />
    <namespace fullname="Amazon.Util.Internal.PlatformServices" preserve="all"/>
  </assembly>
  <assembly fullname="AWSSDK.Lambda" preserve="all">
    <type fullname ="Amazon.*" preserve = "all" />
    <namespace fullname="Amazon.Util.Internal.PlatformServices" preserve="all"/>
  </assembly>
</linker>

I really don’t know what else to try or do, so any help would be appreciated.

@AdamBebko
I managed to fix this, posted my solution in another post post2.

Try the following:

  1. add this to link.xml

<assembly fullname="System.Configuration" preserve="all"/> <method name=".ctor"/> </type> <type fullname="System.ComponentModel.ReferenceConverter"> <method signature="System.Void .ctor(System.Type)" /> </type> </assembly>

  1. Add the following dlls from
    C:\Program Files\Unity\Hub\Editor\2018.4.8f1\Editor\Data\MonoBleedingEdge\lib\mono\unityjit
    to Assets/Plugins/iOS

    -System.Configuration.dll
    -System.Core.dll