# Postfix and header_checks

## NSO

Hello,

 I am trying to use header_checks with Postfix version 2.3.6.

I added this line to 

/etc/postfix/main.cf

```

header_checks = regexp:/etc/postfix/maps/header_checks
```

Also crated 

/etc/postfix/maps/header_checks

```

/^Subject .*TEST/ WARN Spam Header Rule #42
```

And, now, then I try to test it and send email with subject "TEST" - here is no warning in log files, also I tryed REJECT, but it did not rejected as well..

```
Feb 29 13:40:15 xxxx postfix/smtpd[4416]: connect from wa-out-1112.google.com[209.85.146.181]

Feb 29 13:40:16 xxxx postfix/smtpd[4416]: 609A1BEE1C: client=wa-out-1112.google.com[209.85.146.181]

Feb 29 13:40:16 xxxx postfix/cleanup[4419]: 609A1BEE1C: message-id=<7c188f100802290216w44dee06u4df4fdf7ac17e069@mail.gmail.com>

Feb 29 13:40:17 xxxx postfix/qmgr[4403]: 609A1BEE1C: from=<xxxx@xxxxxx.xx>, size=842, nrcpt=1 (queue active)

Feb 29 13:40:19 xxxx postfix/lmtp[4421]: 609A1BEE1C: to=<xxxx@xxxxx.xx>, relay=xxxx.xx[/var/imap/socket/lmtp], delay=3.4, delays=1.3/0.18/0.25/1.7, dsn=2.1.5, status=sent (250 2.1.5 Ok)

Feb 29 13:40:19 xxxx postfix/qmgr[4403]: 609A1BEE1C: removed

Feb 29 13:40:47 xxxx postfix/smtpd[4416]: disconnect from wa-out-1112.google.com[209.85.146.181]

```

Where can I look for this problem?

thx

Lukas

----------

## elgato319

my lines look like this:

```

/^Subject:.*some text/ REJECT SPAM-RULE1

```

did you do a postfix reload after editing main.cf?

----------

## NSO

Yes, I reloaded postfix.

Problem was that I was missing ":" in the end of word "subject".

thx

Lukas

----------

