-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Azure CP is not working at site collection level #127
Comments
Can you check SharePoint logs and filter on Product/Area "AzureCP" to see what happens when you search in the people picker? |
Here is the error we found in ULS logs -
Unexpected [AzureCP] Unexpected error occurred in Initialize, while refreshing configuration: System.IO.FileNotFoundException: Could not load file or assembly 'System.Net.Http, Version=4.2.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified., Callstack: at azurecp.AzureTenant.SetAzureADContext(String claimsProviderName, Int32 timeout) at azurecp.AzureCP.Initialize(Uri context, String[] entityTypes) 3748d49f-2278-7098-2d59-e9c4cf06a353
Also, we observed, it does not work if the site has an alternate access mapping(Custom DNS ) pointed to the webapplication.
It does work if we switch back to a machine hostname(default local url).
Thanks,
Akhilesh
…________________________________
From: Yvan Duhamel ***@***.***>
Sent: 21 June 2021 08:32
To: Yvand/AzureCP ***@***.***>
Cc: Akhilesh Singh ***@***.***>; Author ***@***.***>
Subject: Re: [Yvand/AzureCP] Azure CP is not working at site collection level (#127)
Can you check SharePoint logs and filter on Product/Area "AzureCP" to see what happens when you search in the people picker?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#127 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AURKOKPGPJBYFMS3ST3F72DTT3TH5ANCNFSM467CVEXA>.
|
When I search into the people picker it does not pull the Azure cloud users, Only I can get Local AD users. |
On the SharePoint server which throws this error, can you check the version of this file: |
This is something I can see-
![image](https://user-images.githubusercontent.com/86157097/122892533-199ee980-d363-11eb-849c-d154ad3ed14f.png)
…________________________________
From: Yvan Duhamel ***@***.***>
Sent: 22 June 2021 09:07
To: Yvand/AzureCP ***@***.***>
Cc: Akhilesh Singh ***@***.***>; Author ***@***.***>
Subject: Re: [Yvand/AzureCP] Azure CP is not working at site collection level (#127)
On the SharePoint server which throws this error, can you check the version of this file:
"C:\Windows\Microsoft.NET\Framework64\v4.0.30319\clr.dll"
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#127 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AURKOKP3E2CNVRWZIOFYAF3TUBACJANCNFSM467CVEXA>.
|
The issue has been closed by mistake, Could you please re-open it? So that I can post the comment on it.
…________________________________
From: Akhilesh Singh ***@***.***>
Sent: 22 June 2021 09:34
To: Yvand/AzureCP ***@***.***>; Yvand/AzureCP ***@***.***>
Cc: Author ***@***.***>
Subject: Re: [Yvand/AzureCP] Azure CP is not working at site collection level (#127)
This is something i can see-
[cid:984c630d-1165-4dd3-ada8-9cb2bd4a5437]
________________________________
From: Yvan Duhamel ***@***.***>
Sent: 22 June 2021 09:07
To: Yvand/AzureCP ***@***.***>
Cc: Akhilesh Singh ***@***.***>; Author ***@***.***>
Subject: Re: [Yvand/AzureCP] Azure CP is not working at site collection level (#127)
On the SharePoint server which throws this error, can you check the version of this file:
"C:\Windows\Microsoft.NET\Framework64\v4.0.30319\clr.dll"
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#127 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AURKOKP3E2CNVRWZIOFYAF3TUBACJANCNFSM467CVEXA>.
|
@akkindus I reopened it for you but you could do it yourself. Also, screenshot is not very convenient, please copy as text |
Hi Here is the clr.dll version.! File Version 4.7.3750.0 |
Hi @Yvand , Any update for me. |
@akkindus can you run this PowerShell cmdlet and let me know if it succeeds: [System.Reflection.Assembly]::Load("System.Net.Http, Version=4.2.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a") |
CONFIDENTIAL
Hi,
Here is the output of the command -
PS C:\Windows\system32> [System.Reflection.Assembly]::Load("System.Net.Http, Vesion=4.2.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")
GAC Version Location
--- ------- --------
True v4.0.30319 C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Net.Http\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.Net.Http.dll
…________________________________
From: Yvan Duhamel ***@***.***>
Sent: 28 June 2021 10:16
To: Yvand/AzureCP ***@***.***>
Cc: Akhilesh Singh ***@***.***>; Mention ***@***.***>
Subject: Re: [Yvand/AzureCP] Azure CP is not working at site collection level (#127)
@akkindus<https://github.com/akkindus> can you run this PowerShell cmdlet and let me know if it succeeds:
[System.Reflection.Assembly]::Load("System.Net.Http, Version=4.2.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#127 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AURKOKOKWQ26LNYVTAJWY4TTVA4XDANCNFSM467CVEXA>.
CONFIDENTIAL
|
Sorry to chess you but I have urgent need of solution. Please update - If any...! |
To be honest, I cannot explain why AzureCP cannot load System.Net.Http 4.2.0.0, while it works perfectly fine in plain PowerShell.
[System.Reflection.Assembly]::Load("System.EnterpriseServices, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a") | Out-Null
$publish = New-Object System.EnterpriseServices.Internal.Publish
$publish.GacInstall("C:\path-to-System.Net.Http 4.3.4\System.Net.Http.dll")
Write-Host "Assembly was successfully added to the GAC."
Please let me know the result |
I have a production environment, will this affect anything? |
This is a fairly safe action, as you are only adding a .NET assembly to the cache. And you can easily remove it if needed |
CONFIDENTIAL
Do we need to install this package on all SharePoint servers? would it be possible to share the process of revert back the changes in case something goes wrong - as we have a running production environment?
…________________________________
From: Yvan Duhamel ***@***.***>
Sent: 07 July 2021 16:01
To: Yvand/AzureCP ***@***.***>
Cc: Akhilesh Singh ***@***.***>; Mention ***@***.***>
Subject: Re: [Yvand/AzureCP] Azure CP is not working at site collection level (#127)
This is a fairly safe action, as you are only adding a .NET assembly to the cache. And you can easily remove it if needed
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#127 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AURKOKIPTEWEGZISU5CQN6TTWRT55ANCNFSM467CVEXA>.
CONFIDENTIAL
|
You can install it on only 1 SharePoint server (and test AzureCP on that server only, after you ran iisreset). |
CONFIDENTIAL
I followed the mentioned steps to install System.Net.Http 4.3.4<https://www.nuget.org/packages/System.Net.Http> dll and reset the IIS but still the same issue.
AzureCP is only working for assigning Web application user policy at central admin.
l also checked the logs but did not find any related error
…________________________________
From: Yvan Duhamel ***@***.***>
Sent: 08 July 2021 14:30
To: Yvand/AzureCP ***@***.***>
Cc: Akhilesh Singh ***@***.***>; Mention ***@***.***>
Subject: Re: [Yvand/AzureCP] Azure CP is not working at site collection level (#127)
You can install it on only 1 SharePoint server (and test AzureCP on that server only, after you ran iisreset).
If you need to uninstall the assembly, you can simply remove its folder using the file explorer. It will be located at "C:\Windows\Microsoft.NET\assembly\GAC_MSIL\System.Net.Http\v4.0_4.1.1.3__b03f5f7f11d50a3a"
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#127 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AURKOKPWPVTFEI75IWXHE73TWWSALANCNFSM467CVEXA>.
CONFIDENTIAL
|
Is there any paid support available? |
@akkindus this is not a commercial product, it is a free, open source project and there is no paid support available. |
CONFIDENTIAL
Error is still there recently I performed a search which is logged below error in the log file -
Unexpected [AzureCP] Unexpected error occurred while setting client context for tenant 'mydomain.onmicrosoft.com'.: System.IO.FileNotFoundException: Could not load file or assembly 'netstandard, Version=2.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' or one of its dependencies. The system cannot find the file specified.,
Callstack: at azurecp.AADAppOnlyAuthenticationProvider..ctor(AzureCloudInstance cloudInstance, String tenant, String clientId, String clientSecret, String claimsProviderName, Int32 timeout) at azurecp.AzureTenant.SetAzureADContext(String claimsProviderName, Int32 timeout) 2fe1da9f-f211-7098-2d59-e1101b969ec0
07/12/2021 19:06:26.09 w3wp.exe (0x19394) 0x18C24 AzureCP Lookup 1337 Unexpected [AzureCP] Cannot query Azure AD tenant 'mydomain.onmicrosoft.com' because it was not initialized
07/12/2021 19:06:26.09 w3wp.exe (0x19394) 0x18C24 AzureCP Lookup 1337 Medium [AzureCP] Got 0 users/groups in 0 ms from 'mydomain.onmicrosoft.com' with input 'aksingh'
…________________________________
From: Yvan Duhamel ***@***.***>
Sent: 12 July 2021 13:32
To: Yvand/AzureCP ***@***.***>
Cc: Akhilesh Singh ***@***.***>; Mention ***@***.***>
Subject: Re: [Yvand/AzureCP] Azure CP is not working at site collection level (#127)
@akkindus<https://github.com/akkindus> this is not a commercial product, it is a free, open source project and there is no paid support available.
About your error, you said that you checked the logs and did not find any related error. What do you mean exactly? Is the original System.IO.FileNotFoundException gone?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#127 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AURKOKOTMMQC7NDSWUBVUITTXLOFPANCNFSM467CVEXA>.
CONFIDENTIAL
|
@akkindus I believe I found a fix for this netstandard issue. I did some research: Regarding your netstandard issue: I suggest that you download asset "AzureCP-20.0.20210713.1293-dependencies.zip" from the beta release I just created and extract netstandard.dll (do not extract anything else). [System.Reflection.Assembly]::Load("System.EnterpriseServices, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a") | Out-Null
$publish = New-Object System.EnterpriseServices.Internal.Publish
$publish.GacInstall("C:\Users\yvand\Downloads\AzureCP-20.0.20210713.1293-dependencies\netstandard.dll")
Write-Host "Assembly was successfully added to the GAC." Then, iisreset and check if the issue is resolved |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
CONFIDENTIAL
We are going to test it again by tommarow
Get Outlook for Android<https://aka.ms/AAb9ysg>
…________________________________
From: stale[bot] ***@***.***>
Sent: Friday, August 13, 2021 1:13:18 AM
To: Yvand/AzureCP ***@***.***>
Cc: Akhilesh Singh ***@***.***>; Mention ***@***.***>
Subject: Re: [Yvand/AzureCP] Azure CP is not working at site collection level (#127)
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#127 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AURKOKI4Q35YEMCLV7GRB7DT4QP5NANCNFSM467CVEXA>.
Triage notifications on the go with GitHub Mobile for iOS<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675> or Android<https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email>.
CONFIDENTIAL
|
CONFIDENTIAL
Hi Yvand,
We have installed the AzureCP from the scratch after removing it completely from the sharepoint farm.
We followed the mentioned steps and added dependecies to avoide netstandard dll issue.
But still we are seeing the same behavior where AzureCp only working at central admin level to populate the azure accounts in the people picker.
Any suggestions?
Get Outlook for Android<https://aka.ms/AAb9ysg>
…________________________________
From: Akhilesh Singh ***@***.***>
Sent: Friday, August 13, 2021 3:32:44 PM
To: Yvand/AzureCP ***@***.***>; Yvand/AzureCP ***@***.***>
Cc: Mention ***@***.***>
Subject: Re: [Yvand/AzureCP] Azure CP is not working at site collection level (#127)
We are going to test it again by tommarow
Get Outlook for Android<https://aka.ms/AAb9ysg>
________________________________
From: stale[bot] ***@***.***>
Sent: Friday, August 13, 2021 1:13:18 AM
To: Yvand/AzureCP ***@***.***>
Cc: Akhilesh Singh ***@***.***>; Mention ***@***.***>
Subject: Re: [Yvand/AzureCP] Azure CP is not working at site collection level (#127)
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#127 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AURKOKI4Q35YEMCLV7GRB7DT4QP5NANCNFSM467CVEXA>.
Triage notifications on the go with GitHub Mobile for iOS<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675> or Android<https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email>.
CONFIDENTIAL
|
@akkindus assuming you still get the same error |
CONFIDENTIAL
To reproduce the issue we have created one brand new web application in the same sharepoint farm and enabled SPTrustedIdentityTokenIssuer for AzureAD authentication.
This webapplication using default/local(http://servname:port) alternate access mapping as there is no custom dns pointed at this moment.
By using this default setup AzureCP working fine at site level too.
After after pointing custom DNS to this application like - https://site.mydomain.com its failed to load Azure users in people picker. means stopped working.
I am not sure, what really happening with it, Do you have any idea abut above issue.
…________________________________
From: Yvan Duhamel ***@***.***>
Sent: 23 August 2021 14:41
To: Yvand/AzureCP ***@***.***>
Cc: Akhilesh Singh ***@***.***>; Mention ***@***.***>
Subject: Re: [Yvand/AzureCP] Azure CP is not working at site collection level (#127)
@akkindus<https://github.com/akkindus> assuming you still get the same error System.IO.FileNotFoundException: Could not load file or assembly 'netstandard, Version=2.0.0.0, Culture=neutral, I'm out of ideas.
AzureCP targets .NET framework 4.7.2, not .NET standard. I assume that one of the dependencies need it, but I don't know why this would even be a problem because .NET Framework 4.7.2 supports .NET Standard 2.0<https://docs.microsoft.com/en-us/dotnet/standard/net-standard>.
It looks like the local installation of .NET Framework is missing assemblies, but I don't know how to exactly determine which are those ones.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#127 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AURKOKLZENOD2NJE7X5MLB3T6JFYFANCNFSM467CVEXA>.
Triage notifications on the go with GitHub Mobile for iOS<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675> or Android<https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email>.
CONFIDENTIAL
|
CONFIDENTIAL
Just letting you know we are using a single URL like- https://mysite.domain.com for internal and public access and there are load balancer configured to balance the traffic on this URL.
…________________________________
From: Akhilesh Singh ***@***.***>
Sent: 24 August 2021 10:35
To: Yvand/AzureCP ***@***.***>; Yvand/AzureCP ***@***.***>
Cc: Mention ***@***.***>
Subject: Re: [Yvand/AzureCP] Azure CP is not working at site collection level (#127)
To reproduce the issue we have created one brand new web application in the same sharepoint farm and enabled SPTrustedIdentityTokenIssuer for AzureAD authentication.
This webapplication using default/local(http://servname:port) alternate access mapping as there is no custom dns pointed at this moment.
By using this default setup AzureCP working fine at site level too.
After after pointing custom DNS to this application like - https://site.mydomain.com its failed to load Azure users in people picker. means stopped working.
I am not sure, what really happening with it, Do you have any idea abut above issue.
________________________________
From: Yvan Duhamel ***@***.***>
Sent: 23 August 2021 14:41
To: Yvand/AzureCP ***@***.***>
Cc: Akhilesh Singh ***@***.***>; Mention ***@***.***>
Subject: Re: [Yvand/AzureCP] Azure CP is not working at site collection level (#127)
@akkindus<https://github.com/akkindus> assuming you still get the same error System.IO.FileNotFoundException: Could not load file or assembly 'netstandard, Version=2.0.0.0, Culture=neutral, I'm out of ideas.
AzureCP targets .NET framework 4.7.2, not .NET standard. I assume that one of the dependencies need it, but I don't know why this would even be a problem because .NET Framework 4.7.2 supports .NET Standard 2.0<https://docs.microsoft.com/en-us/dotnet/standard/net-standard>.
It looks like the local installation of .NET Framework is missing assemblies, but I don't know how to exactly determine which are those ones.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#127 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AURKOKLZENOD2NJE7X5MLB3T6JFYFANCNFSM467CVEXA>.
Triage notifications on the go with GitHub Mobile for iOS<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675> or Android<https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email>.
CONFIDENTIAL
|
@akkindus so it seems that you did fix the original error |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Azure CP is not working at site collection level for existing SharePoint web application, but same solution is working for newly created we application even with site collection.
Note : Existing site collection has public DNS pointed and SSL configured at load balancer level.
Azure authentication provider is configured as a SPTrustedIdentityTokenIssuer for both application.
Thanks in advance.
The text was updated successfully, but these errors were encountered: