eve-ng community edition: Current API version: 5.0.1-10
tests with mikrotik CHR routeros 7.2.3 and 6.49.6 eve-ng nodes
Mikrotik routeros recently introduce "force new password" for initial boot
stratup-config no working since stuck on boot with "new password> " prompt (after license agreement)
I found a solution to send control+c on "new password> " prompt but is not fully working
config_mikrotik.py
Code: Select all
def node_login(handler):
...
try:
_license = handler.expect([MTK_PROMPT, r"\[Y/n\]"], timeout=EXPTIMEOUT)
if _license == 1:
handler.send('n\r\n')
# skip new password prompt wiht ctl+c
_pwd_prompt = handler.expect([MTK_PROMPT, r"password> "], timeout=EXPTIMEOUT)
if _pwd_prompt == 1:
handler.sendcontrol('c')
handler.expect(MTK_PROMPT, timeout=EXPTIMEOUT)
except pexpect.exceptions.TIMEOUT:
...
modified node_login(): work with config_put(): aka ros config is reset to default and node is restarted
however after restart look like with config_import(): stuck again on "new password> " prompt
No idea for now why node_login(): not working with config_import(): after config_put(): reboot
I will continue to investigate it when I have a time but I guess for you folks will be more easy to find a fix !!
note: is there a github/gitlab for community edition where I can open issue or eventually PR for fix (if I find such ?)