Sample Header Ad - 728x90

postmap mangled output

0 votes
0 answers
24 views
Why is postmap returning the action mixed in with the input header? # # cat test.eml Return-Path: # cat test_HC /^Return-Path: .*=.*\.com@.*/i REDIRECT spam+track@my.local # cat test.eml | xxd 00000000: 5265 7475 726e 2d50 6174 683a 203c 3638 Return-Path: .. Removing the carriage return makes the output better but valid email syntax requires a carriage return: # cat test.eml | perl -pe 's/[\n\r]+/\n/g' | postmap -q - regexp:test_HC Return-Path: REDIRECT spam+track@my.local OSs: # hostnamectl | grep Operating | perl -pe 's/.*:\s+//g' AlmaLinux 9.6 (Sage Margay) # uname -m aarch64 ###################################################### # hostnamectl | grep Operating | perl -pe 's/.*:\s+//g' CentOS Linux 7 (Core) # uname -m x86_64 https://www.postfix.org/regexp_table.5.html https://www.postfix.org/postmap.1.html Am I doing it wrong or has postfix been broken for a long time?
Asked by user1133275 (5723 rep)
Jun 16, 2025, 07:45 PM
Last activity: Jun 17, 2025, 12:36 PM