-
Notifications
You must be signed in to change notification settings - Fork 4.6k
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
Integrated authentication failing when attempting to connect to SQL Server from macOS Sierra #22863
Comments
For clarity, updated to dotnet 2.0.0 and still seeing the issue. |
This has not been assigned any milestone. Can we get an idea on the timeline? Thanks. |
@carlowahlstedt
We need to get information from |
Do you have the following two lines in your
The first is required to enable GSSAPI (Kerberos) authentication, the second one is required to get ssh to canonicalize the hostname via DNS and use the canonical name to obtain a host service ticket. Without the second one, ssh will use the exact hostname or IP address entered on the command line to try and obtain a host service ticket, and in this case it fails. |
@geleems I created the config file in
I then restarted but realized I should have first gone back through the original setup document. After I did that, it connected! So, looks like that document needs updated with your suggesting of adding these two lines into an ssh config file. Would that be something that makes sense for everyone to make sure they have setup? Seems confusing to me why it would work for many others but not me? Thanks so much for your help @geleems!! |
@geleems This did not work for me. Note: My mac is domain joined. I login as the domain user to the mac. Created ~/.ssh/config file (was missing): Created /etc/krb5.conf file (was missing): [realms] Ran: klist (note I first tried kinit with lowercase domain.com, then uppercase DOMAIN.COM) Credentials cache: API:{GUID} Issued Expires Principal In VSCode: Still get the same error. Rebooted my computer and tried again in VSCode. ❯ dotnet --version |
@Code-DJ What version of macOS are you running? The release notes for v1.1 of the mssql extension states:
|
@carlowahlstedt macOS Sierra. |
I also think I had to update OpenSSL for some other tool I used. Not sure if that's applicable here. I believe I used Homebrew to do the update. You could potentially try that. |
@carlowahlstedt I had 1.0.2k 1.0.2l and it shows that it is the latest version. Thanks. |
@carlowahlstedt |
Thanks @geleems we can close this issue whenever you're satisfied. Thanks again for the help. |
@Code-DJ Can you check those settings in your machine? /etc/pam.d/authorization :
/etc/pam.d/screensaver :
/etc/pam.d/sudo :
~/.ssh/config :
|
@geleems here are the values:
I didn't have the last line in .ssh/config. Didn't work even after adding it. |
@Code-DJ |
@geleems I had never tried ssh using kerberos so not sure what exactly needs to be done but here is what I have tried: I upgraded to macOS High Sierra yesterday I login to my Mac using domain credentials. There are other macs at work that are setup the same way. I ran the following command on my machine to ssh into another: ssh -K ip-address Got the following error: Removed the following line from .ssh/config
Now I have this
Ran the same command: It asked me to enter password, on entering the password it said Authentication failed. |
@Code-DJ |
This issue is originally discussed here.
Following the Kerberos Setup Instructions. Steps 1 through 3 work perfectly. However, when attempting step 4 I get the following:
Per @kevcunnane request, I'm submitting an issue here.
The only other thing I've noticed since the other issue, is that if I run the
klist
command without first running thekinit
command I have several other entries:We do use the Jamf Casper Suite to manage our Macs, and I'm assuming that's what those other entries are from.
Finally, I also setup a .Net Core Console app to see if integrated security would run from there, following along the same lines as this issue and I received the same exception as the one the VS Code is giving me with the mssql extension.
The text was updated successfully, but these errors were encountered: