I think the code that Efaden put on github is probably the best bet since it fixes the length issue, as well as gives us a place to track change, but it didn't have port or ssl support. I forked his code and added those featuers: https://github.com/akschu/MikroTikPerl Efaden, please consider merging...