So damn close
Warning: Serious geek-speak ahead.
I'm setting up a Plone site with ZWiki. One of the cool features in ZWiki is you can subscribe to a wiki and get all comments made on pages sent to you as email. Even cooler is it can be configured to post email replies to those notifications back onto the same wiki page as a comment. (ie: two-way email-enabled web discussion, something I take for granted every day with Conversant).
The way it works is (for mail-in) you configure an alias in your /etc/aliases file that pipes to curl, which posts to a specific URL on the plone server with the email message as one of the form inputs. The method that runs for that specific URL does a bunch of security checking, figures out which wiki page that incoming email belongs on, and does it's thing.
To make it even more fun, it can be integrated with Mailman (list manager).
I got it all configured tonight. It wasn't working. Turns out that file has moved on our server, it's now /etc/mail/aliases. No problem, I moved the configuration over to that file. Tested it by sending an email to the mailman list that the wiki was subscribed to.
My message bounced, there was an error message that said "smrsh: cannot use < in command". You see, with the curl command in the aliases file, you specify an -F 'msg=<-' argument. That says, "send the content (<) of stdin (-) as the value of the msg form input." Unfortunately, smrsh, the shell that sendmail is configured to use for procmail aliases that run commands, doesn't allow some characters to be in the command (for security reasons). And unfortunately, < is one of those characters.
So now what do I do? Hack curl's source to define a different character than < for the -F argument? Any other bright ideas?
Update: Clearly I'm too tired to be doing this. I'm going to bed now. I think what I need to do is make a new shell script that calls my curl command, and call that shell script in the aliases file instead of curl directly. I'll need to symlink to that script in /etc/smrsh to make it work. Goodnight!