I'm trying to configure an OAuth/OpenId connect on Service Providers in WSO2 Identity Server and I'm facing an error:
Error occurred while adding the application : OAuthAdminServiceIdentityOAuthAdminException
wso2-is.log:
[2021-04-23 14:20:35,113] INFO {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil}
- 'admin#carbon.super [-1234]' logged in at [2021-04-23 14:20:35,112+0000]
[2021-04-23 14:24:16,379] ERROR {org.wso2.carbon.identity.oauth.OAuthAdminService}
- org.wso2.carbon.identity.oauth.IdentityOAuthAdminException: Error when adding the application.
An application with the same name already exists.
PS: I don't know if it is correlated but I changed the internal database from h2 to mysql. On IDN_OAUTH_CONSUMER_APPS table is showing CONSUMER_KEY and CONSUMER_SECRET.
What am I missing to do to work in carbon console since is showing Configure yet bellow "OAuth/OpenID Connect Configuration"?
I deleted the Service Provider from WSO2-IS console and also from IDN_OAUTH_CONSUMER_APPS table, and then I've recreated everything again.
Now it is showing on WSO-IS console.
Related
I need to modify my existing code to connect to Microsoft Dynamics 365 instead of an on-premises installation. I'm currently using the Microsoft.Xrm.Tooling.Connector and we want to keep this so that the impact on the code is as low as possible.
So I have updated my connection string to use following format:
AuthType=ClientSecret;url=https://xxx.dynamics.com;ClientId=xxx;ClientSecret=xxx;
I have updated the nuget package Microsoft.CrmSdk.XrmTooling.CoreAssembly to the latest version 9.1.0.64. The other related packages were updated at the same time.
The code I use is:
var client = new CrmServiceClient(connstring);
Unfortunately this is not working in my .net 4.7.1 web.app
I get following errors:
CurrentAccessToken = 'CurrentAccessToken' threw an exception of type 'System.NullReferenceException'
LastCrmError = "One or more errors occurred. => An error occurred while sending the request. => Unable to connect to the remote server => A connection attempt failed because the connected party did not properly respond after a period of time, or established connection fai..."
I have also already tried to add following line but the error stays:
ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12;
To be sure that it's not related to my existing web app I have started a new project and I have included a new web app (mvc) and a new console app. Even in that new project the web app is not working but the console app is working.
A difference I see is that for CrmConnectOrgUriActual the console app contains XRMServices/2011/Organization.svc/web?SDKClientVersion=9.0.45.2156 but in the webapp this is only XRMServices/2011/Organization.svc/
Is there maybe something extra that need to be configured in the web app?
Can someone help me with this?
Update
I was able to see more of the error message and it was mentioning also following message: AuthorityUnable to connect to CRM: Need a non-empty authority
I did a new search on "Need a non-empty authority" based on the full error details.
One of the results was the following article: https://www.kashanahmed.com/2020/06/we-were-trying-to-connect-dynamics-365.html
So it seems that my issue was caused by the proxy server of our company.
Adding following lines in the web.config solved my issue
<system.net>
<defaultProxy useDefaultCredentials="true" enabled="true">
<proxy usesystemdefault="True" proxyaddress="http://theproxy" />
</defaultProxy>
</system.net>
I have created the IIS site and pointed it at the deployment folder. I have enabled stdout logging and this is the error:
info: Microsoft.Extensions.DependencyInjection.DataProtectionServices[0]
User profile is available. Using 'C:\Users\No Managed Code\AppData\Local\ASP.NET\DataProtection-Keys' as key repository and Windows DPAPI to encrypt keys at rest.
fail: Microsoft.EntityFrameworkCore.Query.Internal.QueryCompiler[1]
An exception occurred in the database while iterating the results of a query.
System.Data.SqlClient.SqlException: Cannot open database "KeyStoneDb" requested by the login. The login failed.
Login failed for user 'IIS APPPOOL\No Managed Code'.
So, I added the login to SQL with all the necessary rights. Retested in DEV - fine, but when running IIS I still get the issue. The Application Pool being used is 'No Managed Code'.
Why cant the app not connect to the database?
IIS AppPool accounts are virtual accounts, therefore, they don't actually exist as a normal user on the system.
You can not give access to networked resources using that identity. Shared\network resources like file shares and databases that need to communicate with these accounts need to have the 'domain\machinename$' with appropriate permissions.
Give 'domain\machinename$' appropriate permissions on your DB. That should do it.
I'm getting the following error message in my web browser
firebase.js:75 Uncaught Error: This domain is not authorized for OAuth
operations for your Firebase project. Edit the list of authorized
domains from the Firebase console.
I have downloaded the Firebase web app sample to my local machine, pastet the snippet from the firebase console into the .html file of the "database" sample project and enabled Google as authentication method in the console.
Removing the snippet removes the error, but than it doesn't work at all (unsuprisingly).
Also tried with the "auth" sample project.
I have noticed there is a service disruption reported by Firebase, but unsure if that is the reason.
What am I doing wrong?
for development on your computer (local) you need to be running the project from a local http server - not just from a file. ie the url needs to be something like http://localhost.... not file://.....
then you need to add "localhost" to the firebase console under auth > signin methods > OAuth redirect domains
I'm using WSO2 Identity Server version 5.0.
I’m following this tutorial: https://docs.wso2.com/display/IS500/Configuring+Inbound+Authentication+for+a+Service+Provider#ConfiguringInboundAuthenticationforaServiceProvider-ConfiguringOAuth/OpenIDConnect
But every time I try to add an application in the “OAuth/OpenID Connect Configuration” under “Inboud Authentication Configuration” during the SP configuration, WSO2 gives me this error:
“Error when adding the consumer application. An application with the same name already exists.”
I really doesn’t understand which application refers because this is my first configuration on a fresh installation of WSO2 IS.
Let me know if I can attach more info/file to help finding the solution
I am configuring the Sharepoint for the first time, using the SharePoint Products & Technologies Configuration Wizard. While configuring, i have selected below options:
I am creating a new server farm.
Entered the my machine name as database server name, and specified
the credentials of domain user. This domain user is added to the
login user on my database server with Windows Authentication.
Specified the port number 10100 and selected NTLM authentication
provider.
After clicking Next i am getting below error:
An error has occurred while validating the configuration settings. An exception of type System.FormatException was thrown. Additional exception information: *Input string was not in a correct format.*
In the event viewer no error has been logged. But few Information level logs are logged stating 'Login failed for user ''. Reason: Failed to open the explicitly specified database. [CLIENT: *..*.]'. But i can login to database with the same user with Windows Authentication.
Please suggest few things to resolve this issue.
Thanks.
I came across with same issue. I Did rein-stallion of SQL 2008 R2 with SP1 and reinstalled IIS on SharePoint server. Then issue got fixed.