nicer code to interprete the dbauth token in the agent