'get legal username'

def get_username(self):

    username_quote = urllib.parse.quote_plus(self.user_name)
    username_base64 = base64.b64encode(username_quote.encode('utf-8'))
    return username_base64.decode('utf-8')
