-
Notifications
You must be signed in to change notification settings - Fork 225
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
Can only auth with the personal access token. Username/password tokens always fail with 'Invalid Resource' #174
Comments
Thanks @ChrisMBarr I will take a look. |
I think the recommendation is to not using Basic auth (at the very least it requires an IIS configuration change and invalidates using PAT). If this is the case(I will confirm) we should probably remove this authentication handler from the repo. I am going to check on NTLM as that should work. Is there a specific use case for you to be able to use Basic auth where PAT doesn't work? Looping in @bryanmacfarlane |
I think we can leave it but doc the implications. Also, I don't think PAT was available until TFS2017 |
I am fine using the tokens, however they expire at a max of once a year and I'm just trying to avoid having to go in and "fix" this with a new token every year. Off topic here... but is it possible to generate a PAT that does not expire? |
Any update on this? The NTLM still seems to be broken. Seems like the data is not being passed through correctly:
|
@ChrisMBarr, unfortunately I think the longest expiration period we allow is 1 year as far as I know. |
Concerning NTLM, I'm taking a look and tracking it in #172. I'm going to close since it looks like the basic auth question has been resolved and we're tracking NTLM elsewhere. |
Environment
Node version: 8.3.0
Npm version: 5.8.0
OS and version: Windows 10
vsts-node-api version: 6.5.0
TFS Version: Microsoft Visual Studio Team Foundation Server Version 16.122.27409.2
Issue Description
When creating a
new WebApi()
I am only able to log in with a Personal Access Token handler. When I try using the username/password handlers it fails withError: Invalid Resource
Expected behaviour
I would expect a correct username/password combination to work in the same way a PAT would work.
Actual behaviour
No connection occurs, and the error message
Error: Invalid Resource
is producedCode Examples
I have tried all the above methods to generate a username/password token with my own personal TFS account, and a newly created "bot" account that I plan to use for an automated tool I'm building. Neither work.
Actual logged error in the console
The text was updated successfully, but these errors were encountered: