Sharing tool source to upgrade MikroTik device

Started by iwannabe.r00t, December 05, 2016, 09:42:08 PM

Previous topic - Next topic

iwannabe.r00t

Hello. Code in attachment. First tool, forgive me coding and security patterns:)
This was created for test, and served very well, but it is away from being complete solution(propably need more condition checking, let's say on TODO). Use at own risk.
Save attachment on NetXMS server, make it "+x". Create tool (server command) with name of script and %a as parameter. Command produces output and need allowed output about 3 minutes(depends on connection speed and etc.). Put npk with ROS nearby(adjust path)

---edit
I've uploaded code with flaw(my mistake, saved file between version with hardcoded things and file capable of using all passed arguments), need to edit nearby $mtpass variable. Correct upload when i finish newer version. Beside this typo it is working.