ubuntu / aad-auth

Azure AD authentication module for Ubuntu
GNU Lesser General Public License v3.0
143 stars 22 forks source link

Issue: login fails with ssh #465

Open ottfro1 opened 4 months ago

ottfro1 commented 4 months ago

Is there an existing issue for this?

Describe the issue

login using ssh fails with invalid user when logging on for the first time

if loging on using the X11 gnome environment login works - which creates the home directory - after this ssh login starts working.

However this is a bad situation - we want users to login using ssh and establish portforward for the rdp conneciton.

ssh -L 3390:10.2.0.4:3389 user@company.com@74.234.180.221 mstsc /v:localhost:3390

we have a chicken or egg situation - users can't do the ssh-portforward to use rdp

ubuntu 23.10

We have not installed the microsoft stuff below https://learn.microsoft.com/en-us/entra/identity/devices/howto-vm-sign-in-azure-ad-linux#log-in-by-using-the-azure-cli this allows login using ssh but RDP does not work. I think that ubuntu and microsoft needs to synchronize the efforts here and merge to one working solution.

We want both ssh and RDP.

We would like to use azure netapp files https://learn.microsoft.com/en-us/azure/azure-netapp-files/network-attached-storage-protocols#dual-protocols I want to have a shared home folder/directory that I can access from ubuntu and my windows pc

We need two factor authentication.

How does group membership work? We wnat to have fileshares which a grop of users can access and the groups maintaned in azure entra/ad. there should be documentation and example and how to document.

Steps to reproduce it

ubuntu 23.10

sudo apt update sudo apt upgrade sudo apt install xrdp

do all the steps in the guide https://github.com/ubuntu/aad-auth

sudo apt install aad-cli

Ubuntu users: System information and logs

not applicable

Non Ubuntu users: System information and logs

Environment

Log files

Please redact/remove sensitive information:

aad-auth logs can be found in the system journal and queried with:
`journalctl | grep _aad`

2024-02-23T08:59:32.028940+00:00 Ubuntu sshd[9230]: pam_unix(sshd:auth): check pass; user unknown 2024-02-23T08:59:32.029238+00:00 Ubuntu sshd[9230]: pam_unix(sshd:auth): authentication failure; logname= uid=0 euid=0 tty=ssh ruser= rhost=148.161.189.82 2024-02-23T08:59:34.724554+00:00 Ubuntu sshd[9230]: Failed password for invalid user user@company.com from 148.161.189.82 port 25980 ssh2

Application settings

Please redact/remove sensitive information:

You can get the configuration file from /etc/aad.conf

Relevant information

n/A

Double check your logs