implement auth&host