rspamd-pipe-ham 455 B

1234567891011
  1. #!/bin/bash
  2. FILE=/tmp/mail$$
  3. cat > $FILE
  4. trap "/bin/rm -f $FILE" 0 1 2 3 13 15
  5. cat ${FILE} | /usr/bin/curl -H "Flag: 11" -s --data-binary @- --unix-socket /var/lib/rspamd/rspamd.sock http://rspamd/fuzzydel
  6. cat ${FILE} | /usr/bin/curl -s --data-binary @- --unix-socket /var/lib/rspamd/rspamd.sock http://rspamd/learnham
  7. cat ${FILE} | /usr/bin/curl -H "Flag: 13" -s --data-binary @- --unix-socket /var/lib/rspamd/rspamd.sock http://rspamd/fuzzyadd
  8. exit 0