Restore legacy utils

do we want to have a hard dependency on mbstring, or should we detect the availability of the extension and fallback to ``strlen`` ?