[rancid] Mikrotik + ssh with cert + rancid + as rancid user = can not login ?
Lukasz Sokol
el.es.cr at gmail.com
Fri Mar 13 15:19:26 UTC 2015
On 13/03/15 14:40, heasley wrote:
> Fri, Mar 13, 2015 at 01:42:56PM +0000, Lukasz Sokol:
>> rancid at george:~$ bin/mtlogin myrouter
>> myrouter
>> spawn ssh -c 3des -x -l myuser+ct myrouter
>
> what is the full spawn line above?
>
running strace mtlogin -d myrouter ( > session 2>>session) does show amongst others:
open("/var/lib/rancid/.cloginrc", O_RDONLY|O_LARGEFILE) = 6
fcntl64(6, F_SETFD, FD_CLOEXEC) = 0
ioctl(6, SNDCTL_TMR_TIMEBASE or TCGETS, 0xbf8ed108) = -1 ENOTTY (Inappropriate ioctl for device)
read(6, "add user * myuser\nadd passwor"..., 4096) = 128
read(6, "", 4096) = 0
close(6) = 0
write(1, "myrouter\n", 15) = 15
brk(0xa01a000) = 0xa01a000
write(1, "spawn", 5) = 5
write(1, " ", 1) = 1
write(1, "ssh", 3) = 3
write(1, " ", 1) = 1
write(1, "-c", 2) = 2
write(1, " ", 1) = 1
write(1, "3des", 4) = 4
write(1, " ", 1) = 1
write(1, "-x", 2) = 2
write(1, " ", 1) = 1
write(1, "-l", 2) = 2
write(1, " ", 1) = 1
write(1, "myuser+ct", 12) = 12
write(1, " ", 1) = 1
write(1, "myrouter", 14) = 14
write(1, "\r\n", 2) = 2
open("/dev/ptmx", O_RDWR) = 6
(as rancid user) so the line above seems to be what gets spawned?
And the mtlogin ran as 'lukasz' user, doesn't do /anything/ different here either...
so the joke is on ssh probably ?
el es
More information about the Rancid-discuss
mailing list