$Log$
+ Revision 612.8 2003/12/09 05:12:49 ajc
+ * Don't give away anonymous poster information in IMAP or RFC822
+
Revision 612.7 2003/12/09 04:50:16 ajc
* Painstakingly combed through IMAP headers and responses for two hours in
an attempt to figure out why the horrendous pile of crap called Microsoft
Fri Jul 10 1998 Art Cancro <ajc@uncensored.citadel.org>
* Initial CVS import
+
void imap_output_envelope_from(struct CtdlMessage *msg) {
char user[1024], node[1024], name[1024];
+ /* For anonymous messages, it's so easy! */
+ if (!is_room_aide() && (msg->cm_anon_type == MES_ANONONLY)) {
+ cprintf("((\"----\" NIL \"x\" \"x.org\")) ");
+ return;
+ }
+ if (!is_room_aide() && (msg->cm_anon_type == MES_ANONOPT)) {
+ cprintf("((\"anonymous\" NIL \"x\" \"x.org\")) ");
+ return;
+ }
+
+ /* For everything else, we do stuff. */
cprintf("(("); /* open double-parens */
imap_strout(msg->cm_fields['A']); /* personal name */
cprintf(" NIL "); /* source route (not used) */
+
if (msg->cm_fields['F'] != NULL) {
process_rfc822_addr(msg->cm_fields['F'], user, node, name);
imap_strout(user); /* mailbox name (user id) */
PerformUserHooks(luser, (-1L), EVT_OUTPUTMSG);
- if (strlen(fuser) > 0) {
+ if (!is_room_aide() && (TheMessage->cm_anon_type == MES_ANONONLY)) {
+ cprintf("From: x@x.org (----)%s", nl);
+ }
+ else if (!is_room_aide() && (TheMessage->cm_anon_type == MES_ANONOPT)) {
+ cprintf("From: x@x.org (anonymous)%s", nl);
+ }
+ else if (strlen(fuser) > 0) {
cprintf("From: %s (%s)%s", fuser, luser, nl);
}
else {