admin scripts
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

15 line
341 B

  1. #! /bin/bash
  2. # Input : a file with a list of email addresses (one address per line)
  3. # Check if the email is in our ldap, if not return the email address.
  4. FILE=/home/aziz/emails.new
  5. while read line
  6. do
  7. if [ -z "$(ldapsearch -D cn=root,ou=ldap,o=redbrick -xLLL -y /etc/ldap.secret "altmail=$line" uid)" ]
  8. then
  9. echo $line
  10. fi
  11. done <$FILE