home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / mail / misc / 4227 < prev    next >
Encoding:
Text File  |  1993-01-04  |  1.9 KB  |  44 lines

  1. Newsgroups: comp.mail.misc
  2. Path: sparky!uunet!gatech!paladin.american.edu!darwin.sura.net!uvaarpa!murdoch!fermi.clas.Virginia.EDU!gl8f
  3. From: gl8f@fermi.clas.Virginia.EDU (Greg Lindahl)
  4. Subject: putting addresses in a canonical form
  5. Message-ID: <1993Jan4.044344.24439@murdoch.acc.Virginia.EDU>
  6. Sender: usenet@murdoch.acc.Virginia.EDU
  7. Organization: Department of Astronomy, University of Virginia
  8. Date: Mon, 4 Jan 1993 04:43:44 GMT
  9. Lines: 33
  10.  
  11. In an attempt to reinvent the wheel, I have written some code which
  12. groks From: lines and attempts to convert the address into a canonical
  13. form, so that a mail server that I am writing can guess out who
  14. someone is despite GECOS changes and also puzzle out screwed up
  15. addresses.
  16.  
  17. Since this is my first attempt at anything related to RFC822, I have
  18. undoubtedly gotten things wrong. So, does anyone have a set of From:
  19. lines with extremely funky addresses that I can use to test my code?
  20. I'd like the entire line, including comments, i.e.
  21.  
  22. From: Greg Lindahl <gl8f@virginia.edu>
  23. From: Greg (foo) Lindahl <gl8f@virginia.(foo)edu>
  24. From: Greg (foo) Lindahl <gl8f@virginia.     (foo) edu>
  25. From: Greg "foo" Lindahl <gl8f@virginia.(foo)edu>
  26. From: Greg "<foo>" Lindahl <gl8f@virginia.(foo)edu>
  27. From: "Greg Lindahl" <gl8f@virginia.(foo)edu>
  28. From: "Greg Lindahl"<gl8f@virginia.(foo)edu>
  29. From: "Greg L\"indahl" <gl8f@virginia.(foo)edu>
  30. From: gl8f@virginia.edu (Greg Lindahl)
  31. From: gl8f@virginia.edu (Greg "<foo>" Lindahl)
  32. From: gl8f@virginia.edu (Greg "<foo>")
  33. From: gl8f@virginia.edu (Greg "<fo\"o>" Lindahl)
  34. From: Greg "<foo>" Lindahl <"gl8f"@virginia.(foo)edu>
  35.  
  36. These examples only test comment deletion and figuring out which part
  37. of the string is the address. My code reduces all of those strings to
  38. "gl8f@virginia.edu", except the last, which is
  39. "\"gl8f\"@virginia.edu".  I'd like some similar examples plus some
  40. funky looking addresses.  Surely someone has generated a torture test
  41. of this type?
  42.  
  43. Thanks in advance.
  44.