EvilFreelancer / routeros-api-php

Mikrotik RouterOS API PHP client for your applications
https://mikrotik.com/software
MIT License
402 stars 149 forks source link

/export does not work ROUTEROS7 #106

Closed Lilleri closed 1 year ago

Lilleri commented 1 year ago

Version of RouterOS 7.11.2

To Reproduce use the function export() or perform a query with the endpoint /export

Expected behavior i expect to output the configuration of the mikrotik

In summary when i use export() or perform the query /export instead of receiving the configuration i receive this error bad command name bash (line 1 column 1) i saw that this error is caused by this parameter bash -se when it tries to connect to the SSH to retrieve the configuration, if i remove that i receive with success the configuration

EvilFreelancer commented 1 year ago

Hi, thanks for your report! Can you create a PR with your fix?

Lilleri commented 1 year ago

hello, i just made the PR, i cannot test if this works in the previous RouterOS versions too.

EvilFreelancer commented 1 year ago

@Lilleri hi! Your fix was merged, thanks!

You may try update to 1.5.1