Make python-basicauth compatible with Python 3