Skip to content
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

SharePoint online authentication failed - Used username and password to authenticate using node js in Azure Function #122

Open
ranjinie opened this issue Jan 24, 2023 · 0 comments

Comments

@ranjinie
Copy link

i am getting errors when I try to connect to SharePoint from Visual studio code using node js and Azure Function. Please advise how to resolve this issue. thank you,
[error] Worker 49137137-f7de-4769-8170-1bc0d01f5abc uncaught exception (learn more: https://go.microsoft.com/fwlink/?linkid=2097909 ): Error: <s:Fault> <s:Code>

<s:Value>s:Sender</s:Value>     <s:Subcode>       <s:Value xmlns:a="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd">a:FailedAuthentication</s:Value>    

</s:Subcode> </s:Code> <s:Reason> <s:Text xml:lang="en-US">ID3242: The security token could not be authenticated or authorized.</s:Text> </s:Reason> </s:Fault> at C:\APM_D365\AzureFunction\APMS\node_modules\node-sp-auth\lib\src\utils\AdfsHelper.js:31:23 at processTicksAndRejections (node:internal/process/task_queues:96:5)

[2023-01-23T23:54:20.749Z] Exception encountered while listening to EventStream

[2023-01-23T23:54:20.750Z] Language Worker Process exited. Pid=35896.

[2023-01-23T23:54:20.750Z] System.Private.CoreLib: The request stream was aborted. The HTTP/2 connection faulted. System.Private.CoreLib: An existing connection was forcibly closed by the remote host. Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets: An existing connection was forcibly closed by the remote host.

[2023-01-23T23:54:20.751Z] node exited with code 1 (0x1). LanguageWorkerConsoleLog[error] Worker 49137137-f7de-4769-8170-1bc0d01f5abc uncaught exception (learn more: https://go.microsoft.com/fwlink/?linkid=2097909 ): Error: <s:Fault> <s:Code> <s:Value>s:Sender</s:Value> <s:Subcode> <s:Value xmlns:a="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd">a:FailedAuthentication</s:Value> </s:Subcode> </s:Code> <s:Reason> <s:Text xml:lang="en-US">ID3242: The security token could not be authenticated or authorized.</s:Text> </s:Reason> </s:Fault> at C:\APM_D365\AzureFunction\APMS\node_modules\node-sp-auth\lib\src\utils\AdfsHelper.js:31:23 at processTicksAndRejections (node:internal/process/task_queues:96:5).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant