New answers tagged

0

Now I could putty to the VM. The VM is hosted on VMware and IP addresses is supplied through DCHP. After logging into the machine I could no see the IP address. Thus gave ifdown eth0 ifup eth0 . Then tried putty again and that time it first time asked Yes/No question on finger print as I configured ssh key for root user. Then tried logging in as sudo user ...


0

Your server might be setup to disallow password authentication, e.g., requiring Kerberos (not well supported by PuTTY), or a private key. For the former, the KerberosOrLocalPasswd and UsePAM might be useful. PuTTY works (except when Kerberos is intruding) well enough with a private key. For reference: sshd_config - OpenSSH SSH daemon configuration file ...


0

The modem I have is a SmartRG SR505N I did do a bunch of netstat and looking around, and eventually did find that even though the router says it moved it's own ssh port 22 to 2222 after I enabled port forwarding to my lan side server, it doesn't actually move it's own ssh server, but it's weird, sometimes it would work, other times it wouldn't. I read about ...


1

If you cannot confirm that key fingerprint as coming from your ubuntu host, the likely cause is that you are not really connecting to the host/service that you think you are. Not only are you getting a different host key, the key length of 1040 seems a bit peculiar. Doing a quick google search on the fingerprint 86:03:d0:87:3d:67:3a:9a:9b:83:7a:39:a7:2e:e7:...


0

The directory owner and permission are correct. During configuration use the PrivilegeSeparation option. Start the demon as service cygrunsrv -S sshd Example of directory permission on a functional system $ icacls $(cygpath -w /var/empty) E:\cygwin64\var\empty NULL SID:(DENY)(Rc,S,REA,X,DC) MATZERI\cyg_server:(F) ...


0

The pam_script module uses its exit status to tell the calling stack what to do. Change your code to this, and it'll work: #!/bin/bash username="$1" if [[ root != "$username" ]] && grep -q '^'"$username"':' /etc/passwd then echo "Warning, please user your AD credentials" exit 1 fi exit 0 I've excluded root from the block. You can adjust ...


0

Changing the shell for relevant accounts in /etc/passwd would work well Put this into (say) /usr/local/etc/mustuseadlogin and make it executable: #!/bin/sh echo echo "Please log in with AD authentication" >&2 echo sleep 10 exit 0 Now edit /etc/passwd (ideally with vipw) and change the last field for all affected accounts to be /usr/local/etc/...


0

Awesome solution for standard 'login'. Unfortunately, I don't think you'll have much luck getting this same behavior going for 'sshd'. This is due to the fundamental connection procedures which sshd utilizes when establishing a connection. By the time we get so far as the PAM stack (or profile bits, as in the other suggestion), the username is already ...


0

Using id it is relatively easy to know if you are connected from ad or local /etc/passwd. next step would be to have a function in /etc/profile that will issue the warning message.



Top 50 recent answers are included