parameterize with defaults for most params;
add active directory support with 'directory_type=ad';