Junk Mail AppleScripts

I've received email messages from others where my email address wasn't in their address book--so my message was defined as spam.
The message asked me to call (no number, meaning I needed to know the recepient) to have my email address added to their address book.
Is there an AppleScript that will automatically send this form email to every spam email I get...and then delete the spam email?
I'm already forwarding it all to a Junk Mail folder, but it's starting to get absurd with hundreds of spam emails daily.

Thanks for the response, but I've already set up a Junk Mail folder and have junk mail going into it.
I don't want to deal with it any more, but I don't want to miss those few that slip through into Junk Mail that shouldn't because they have a new email or whatever.
To be more specific, this is what I'd like to have happen:
1. An incoming email message is catagorized as Junk through the Junk Mail filter.
2. A form reply is generated that says, "I've been getting hundreds of spam emails lately, so I've had to bounce them back. If this message comes to you and you legitimately need to contact me, please call me to put your email address into my address book. Sorry for the inconvenience."
3. The Junk message is deleted...not put into a Junk folder...deleted automatically.
Is there an AppleScript that will do this for me?
Thanks!
Arlaine

Similar Messages

  • Automator/applescript to forward junk mail as attachment...how?

    I finally came up with a real use for Automator and Applescript -- I was delighted.
    I want to modify my junk mail rule to run an Applescript that forwards a mail message as an attachment (not just a regular forward) to Spamcop.
    It has to be forwarded as an attachment. First shot, I simply went to modify my junk mail rule but, alas, found that "forward as attachment" is not an option for Mail's rules. Fortunately, there is a "run Applescript" option so...
    I fired up Automator, hoping to see how to tell Mail to forward a message as an attachment. Again, alas, no "as attachment" option there. So then I started exploring how to invoke the Mail menu item Message > Forward as Attachment but, haven't been able to figure it out.
    Any help would be appreciated. Especially since this will be the first time I've actually found a use for Automator, which is great... I just know it's not merely eye candy...

    Here is some starter code, to be saved into the current users' '~/Library/Scripts/Applications/Mail/' folder - as a script file ...
    using terms from application "Mail"
    on perform mail action with messages tMessages
    repeat with i in tMessages -- Cycle throught the list of incoming 'Rule' filtered e-Mail messages.
    -- File path file Name of temporary attachement file.
    set file_Name to (((path to home folder from user domain) as string) & (do shell script "date +%Y%m%d%H%M%StempFile.txt"))
    try -- Capture any unexpected AppleScript error.
    set FREF to open for access file file_Name with write permission -- Create temporary attachement file.
    write ((source of i) as string) to FREF starting at 0 -- Write to temporary attachement file.
    close access FREF -- Close temporary attachement file.
    -- Make new outgoing e-Mail message, and attach respective attachment file.
    set tMessage to make new outgoing message with properties {visible:true, subject:"My Subject", content:("My Body" & return & return)}
    tell content of tMessage
    make new attachment with properties {file name:(file_Name as alias)} at after last paragraph
    end tell
    end try
    try -- Capture any unexpected AppleScript error.
    tell application "Finder" to delete file file_Name -- Trash temporary attachement file.
    end try
    end repeat
    end perform mail action with messages
    try -- Capture any unexpected AppleScript error.
    tell application "Finder" to empty trash -- Delete all temporary attachement files (plus all other items) in the trash can.
    end try
    end using terms from

  • Problem Removing Junk Mail from POP Server

    Is there a way to automatically remove junk mail from the POP server when I delete the Junk within the Apple Mail application?
    The Mail application Junk filter is working pretty well for me on my primary MacBook Pro system. My inbox is mostly junk free and I like that I can check the Junk folder to see if any "good" e-mail got snared before deleting the junk from the junk folder.
    However, "Erasing Junk Mail" from the junk mail folder does NOT erase the junk from my POP server. So if I check the same e-mail account on another computer or my Treo, I have endure the same junk messages again which can quickly mount up to 100+ messages over the course of a day.
    I can manually delete messages from the POP server by using the Get Info window in the Shortcuts/Actions Menu at the bottom left of the Mail browser.
    However, I have to manually identify and select the junk messages from all the mail on the POP server to delete it which is both tedious and time consuming.
    Isn't there some way instruct the program to automatically delete Junk from the server when it's deleted from the browser?
    It seems like it would be an obvious feature.
    I've looked for some way to do this including apple scripts but I can't find a way to do it.
    Thanks in advance for any help or suggestions.

    michellzappa,
    All of my e-mail providers have some sort of web based access for my accounts. They identify, segregate and prevent any message marked as bounce from being downloaded to my inbox. Is this what you are describing as redundant?
    Mail Scripts 2.7.10 by Andreas Amann, provides an excellent compilation of mail scripts.
    I would advise that you create a new post with the title. "Can I write an applescript to automatically clean out messages on server every hour?" in the AppleScript Forum.
    ;~)

  • Mail Applescript?

    Is there an AppleScript or other way to designate certain emails as spam?
    I don't want them deleted I just want them to be added to a Rule so they'll automatically get put in a certain folder.
    Thanks for your help.

    dnucks wrote:
    Is there an AppleScript or other way to designate certain emails as spam?
    If it's just a specific email, then just create a Rule: Mail->Preferences->Rules->Add Rule
    Also, turn on Apple Mail's built-in spam filter: Mail->Preferences->Junk Mail->Enable junk mail
    For a more complex Blacklist/Whitelist filter to catch those sneaky spam emails, here's what I use:
    First turn on Apple Mail's built-in spam filter: Mail->Preferences->Junk Mail->Enable junk mail filtering
    Then set a Mail Rule as:
    If any [ Message type ] is [ Mail ]
    Perform the following actions:
    [ Move message ] to mailbox [ inbox ]
    [ Run Applescript ] ~/Documents/Scripts/Junkfilter.scpt
    Then create Junkfilter.scpt:
    <pre style="
    font-family: Monaco, 'Courier New', Courier, monospace;
    font-size: 10px;
    font-weight: normal;
    margin: 0px;
    padding: 5px;
    border: 1px solid #000000;
    width: 720px; height: 340px;
    color: #000000;
    background-color: #E6E6EE;
    overflow: auto;">
    using terms from application "Mail"
    on perform mail action with messages theMessages
    tell application "Mail"
    repeat with theMessage in theMessages
    set theSender to (sender of theMessage)
    set theReplyto to (reply to of theMessage)
    set theSubject to (subject of theMessage)
    set theHeader to (all headers of theMessage)
    set theContent to (source of theMessage as string)
    if my blacklist(theSender, theReplyto, theSubject, theHeader, theContent) ¬
    and not my whitelist(theSender) then
    my moveToJunkFolder(theMessage)
    end if
    end repeat
    end tell
    end perform mail action with messages
    end using terms from
    on blacklist(f, r, s, h, c)
    if f contains "registrationchecks.com" or ¬
    f contains "busenetwork.net" or ¬
    r contains "1105service.com" or ¬
    s contains "Codeine" or ¬
    h contains "X-YahooFilteredBulk" or ¬
    h contains "Received-SPF: fail" or ¬
    h contains "Received-SPF: softfail" or ¬
    h contains "Received-SPF: error" or ¬
    h contains "Received-SPF: permerror" or ¬
    h contains "Received-SPF: temperror" then
    return true
    else
    try -- Check Content of Message:
    do shell script "echo " & quoted form of c & " | egrep -qs 'http://.*\.ru|http://.*\.ly|http://.*\.in|http://trk.cp.*\.com|<div id="hidden">|http://a\.nf/'  "
    on error -- non-zero exit status: grep retuns 1 if not found or 2 if error
    return false
    end try
    return true -- zero exit status: grep retuns 0 if selected lines are found 
    end if
    end blacklist
    on whitelist(f)
    if f contains "aicpa" or ¬
    f contains "iLounge.com" or ¬
    f contains "wikimedia.org" then
    return true
    else
    return false
    end if
    end whitelist
    on moveToJunkFolder(m)
    tell application "Mail"
    try
    -- set the junk mail status of m to true -- DO NOT USE!! Causes "*** Assertion failure"
    set read status of m to true
    set the background color of m to orange
    end try
    try
    set theAccount to (account of mailbox of m)
    set mailbox of m to (mailbox "Junk" of theAccount) --  Move to "Junk"
    end try
    end tell
    end moveToJunkFolder
    </pre>

  • Thunderbird fails to send email when "Scan email for junk mail" option is checked in Server Admin

    I have 2 clients that need to send mail through my server, one Mac and one Windows. The Mac uses apple mail and the Windows machine uses Thunderbird.
    Apple Mail will send fine, it is set up for "Use Default ports 25, 465, 587" and "Use SSL" and "Authentication: MD5 Challenge-response".
    Thunderbird refuses to send and I don't even see any errors showing up in the Console on the OS X server under smtpd entries.
    If I uncheck the "Scan email for junk mail" option on the server, then Thunderbird will send fine.
    Thunderbird is set up as: "smtp port 587 (default)" "connection security: STARTTLS" "Authentication method: Encrypted Password"
    May or may not be relevant: I use virtual domains as well as aliases.
    Server: Mac OS X Server version 10.5.8

    Solved it, looks like maybe the smtpd settings for sasl authentication may not have been correct. I followed everything in http://osx.topicdesk.com/content/view/38/41/ the "Frontline Spam Defense for OS X server" guide and now can send mail just fine from Thunderbird Winodws and from Apple Mail.

  • How can I migrate my junk-mail settings from one Mac to another?

    I would like to move my junk mail settings from one Mac to another. I found this article (https://kb.siteground.com/how_to_synchronize_the_junk_email_settings_in_mac_mail /), but can't locate the file indicated in the article, so I suspect that the article is out of date (though it's not dated).
    Both machines - MacOS 10.9.5; Mail 7.3.
    Any insights much appreciated!
    Best,
    Doug

    Make your user library visible and see if you can find it.
    Go to Finder and select your user/home folder. With that Finder window as the front window, either select Finder/View/Show View options or go command - J.  When the View options opens, check ’Show Library Folder’. That should make your user library folder visible in your user/home folder.  Select Library.

  • Mail going to the Junk Mail folder but not marked as Junk Mail

    Hi,
    Hopefully someone can help me. It's something I had done but I don't know what I have done. All of a sudden all my emails from eBay are going directly to my Junk Mail folder, although when I try to click them as 'Not Junk' (Thumbs Up) they are not even selected as Junk Mail and I can still select them to be Junk Mail.
    At the moment I'm just dragging them back into the correct folder but it still keeps happening. (I sell a lot on eBay so it's happening quite often).
    Any help would be much appreciated.
    Thanks!

    Hi Corey,
    Check your settings as outlined in this link:
    Mail (Mavericks): Change the junk mail filter
    Cheers,
    GB

  • Classified junk mail intermittently not moving to junk folder

    Hello,
    I am running Thunderbird 31.3.0 and all of a sudden the junk mail (which is classified and marked) is not being moved to the junk mail folder intermittently on some of the IMAP accounts setup on Thunderbird.
    Again, this problem only intermittently occurs but it seems to happen on the same couple of email accounts. The junk mail is marked and stays in the inbox but does not automatically move to the junk folder. If I unmark one in the inbox and remark it - it moves automatically. if I restart Thunderbird, all newly received junk moves as expected for a time until the problem intermittently start occurring again.

    One last thing to try:
    http://kb.mozillazine.org/Standard_diagnostic_-_Thunderbird

  • Junk Mail won't move to Junk folder after training+switching to automatic

    After training for months, I switched my preferences to automatic and now my existing junk mail doesn't move to the junk folder.
    Dual 2 GHz PowerPC G5   Mac OS X (10.4.3)  

    Same problem here - also using an IMAP account. Junk mail is labeled correctly but does not move automatically to the junk folder even though the option to do that is enabled in preferences.

  • Junk mail not automatically moved to Junk folder

    Hello.
    I'm using an IMAP account and have configured Mail to move junk mail to the chosen junk mail folder (junk is not filtered on the server but on my client). Since the junk mail filter is still learning sometimes junk mail is not detected and still goes to the inbox. That's okay.
    If I then select that message it is somehow miraculously detected and marked as junk. However, it is not automatically moved to the junk folder but remains in the inbox marked as junk?
    Is this desired behaviour? Why is the mail not automatically moved to the junk folder, like it is when I manually mark a mail as junk?
    Thanks in advance

    I just happened to notice that even mail that is automatically marked as spam/junk remains in my inbox. So I open the inbox folder and there is message that is marked as junk. Only when I manually reset and set the junk status is the message moved to the junk folder.
    This seems to be the case in an IMAP acount where all folders (sent, drafts, spam, etc.) are subfolders of the actual inbox folder.
    Is anyone else experiencing this behaviour?
    Thanks in advance

  • Why isn't junk mail going into its folder

    I get a lot of spam and a few weeks ago, it went into my junk folder which pulled if off my iphone and ipad. Now the junk mail just stays in the inbox.
    What is causing that or this?
    Can I fix it?

    Try rebuilding your mailboxes ...
    Instructions >  Mail (Mavericks): Rebuild mailboxes

  • Urgent help needed with un-removable junk mail that froze Mail!!

    Urgent help needed with un-removable junk mail that froze Mail?
    I had 7 junk mails come in this morning, 5 went straight to junk and 2 more I junked.
    When I clicked on the Junk folder to empty it, it froze Mail and I can't click on anything, I had to force quit Mail and re-open it. When it re-opens the Junk folder is selected and it is froze, I can't do anything.
    I repaired permissions, it did nothing.
    I re-booted my computer, on opening Mail the In folder was selected, when I selected Junk, again, it locks up Mail and I can't select them to delete them?
    Anyone know how I can delete these Junk mails from my Junk folder without having to open Mail to do it as it would appear this will be the only solution to the problem.

    Hi Nigel
    If you hold the Shift key when opening the mail app, it will start up without any folders selected & no emails showing. Hopefully this will enable you to start Mail ok.
    Then from the Mail menus - choose Mailbox-Erase Junk Mail . The problem mail should now be in the trash. If there's nothing you want to retain from the Trash, you should now choose Mailbox- Erase Deleted Messages....
    If you need to double-check the Trash for anything you might want to retain, then view the Trash folder first, before using Erase Junk Mail & move anything you wish to keep to another folder.
    The shift key starts Mail in a sort of Safe mode.

  • James Send to Junk Mail

    Hello , i am using james 2.2.0 installed on a server with a online DNS , it recives mails properly , but when i try to send emails ( also when using Authenticated SMTP) , mail go to junk mails ( as hotmail and yahoo) , When i use Outlook express outside the server to send mail i get the following error :
    The message could not be sent because one of the recipients was rejected by the server. The rejected e-mail address was '[email protected]'. Subject 'hahahhaha', Account: 'mytrans-port.com', Server: 'mytrans-port.com', Protocol: SMTP, Server Response: '550 - Requested action not taken: relaying denied', Port: 25, Secure(SSL): No, Server Error: 550, Error Number: 0x800CCC79
    here is my config.xml , Thanks
    <?xml version="1.0"?>
    <!DOCTYPE config [
    <!ENTITY listserverConfig SYSTEM "../conf/james-listmanager.xml">
    <!ENTITY listserverStores SYSTEM "../conf/james-liststores.xml">
    <!ENTITY fetchmailConfig SYSTEM "../conf/james-fetchmail.xml">
    ]>
    <!--  Configuration file for the ASF James server -->
    <!--  This file contains important settings that control the behaviour -->
    <!--  of all of the services and repositories. -->
    <!--                               README!                            -->
    <!-- This configuration file is designed to run without alteration for simple tests. -->
    <!-- It assumes you have a DNS server on localhost and assigns a root password of root. -->
    <!-- In case the defaults do not suit you, the items you are most likely to need to change -->
    <!-- are preceded by a CHECKME! or CONFIRM? comment in the left margin. -->
    <!-- For production use you will probably need to make more extensive changes, see -->
    <!-- http://james.apache.org/documentation_2_1.html -->
    <!-- $Revision: 1.40.2.26 $ Committed on $Date: 2004/06/16 02:42:08 $ by: $Author: noel $ -->
    <config>
       <James>
    <!-- CHECKME! -->
          <!-- This is the postmaster email address for this mail server. -->
          <!-- Set this to the appropriate email address for error reports -->
          <!-- If this is set to a non-local email address, the mail server -->
          <!-- will still function, but will generate a warning on startup. -->
          <postmaster>Postmaster@localhost</postmaster>
          <!-- servernames identifies the DNS namespace served by this instance of James. -->
          <!-- These servernames are used for both matcher/mailet processing and SMTP auth -->
          <!-- to determine when a mail is intended for local delivery. -->
          <!-- -->
          <!-- If autodetect is TRUE, James wil attempt to discover its own host name AND -->
          <!-- use any explicitly specified servernames. -->
          <!-- If autodetect is FALSE, James will use only the specified servernames. -->
          <!-- -->
          <!-- If autodetectIP is not FALSE, James will also allow add the IP address for each servername. -->
          <!-- The automatic IP detection is to support RFC 2821, Sec 4.1.3, address literals. -->
          <!-- -->
          <!-- To override autodetected server names simply add explicit servername elements. -->
          <!-- In most cases this will be necessary. -->
          <!-- By default, the servername 'localhost' is specified. This can be removed, if required. -->
          <!-- -->
          <!-- Warning: If you are using fetchpop it is important to include the -->
          <!-- fetched domains in the server name list to prevent looping.       -->
          <servernames autodetect="true" autodetectIP="true">
    <!-- CONFIRM? -->
             <servername>mytrans-port.com</servername>
          </servernames>
          <!-- Set whether user names are case sensitive or case insensitive -->
          <!-- Set whether to enable local aliases -->
          <!-- Set whether to enable forwarding -->
          <usernames ignoreCase="true" enableAliases="true" enableForwarding="true"/>
          <!-- The inbox repository is the location for users inboxes -->
          <!-- Default setting: file based repository - enter path ( use  "file:///" for absolute) -->
          <inboxRepository>
             <repository destinationURL="file://var/mail/inboxes/" type="MAIL"/>
          </inboxRepository>
          <!-- Alternative inbox repository definition for DB use. -->
          <!-- The format for the destinationURL is "db://<data-source>/<table>" -->
          <!-- <data-source> is the datasource name set up in the database-connections block, below -->
          <!-- <table> is the name of the table to store user inboxes in -->
          <!-- The user name is used as <repositoryName> for this repository config. -->
          <!--
          <inboxRepository>
             <repository destinationURL="db://maildb/inbox/" type="MAIL"/>
          </inboxRepository>
          -->
          <!-- Alternative inbox repository definition for DB use. -->
          <!-- Stores message body in file system, rest in database -->
          <!--
          <inboxRepository>
             <repository destinationURL="dbfile://maildb/inbox/" type="MAIL"/>
          </inboxRepository>
          -->
          <!-- Alternative inbox repository definition for mbox use. -->
          <!-- This method uses UNIX standard mbox files and is meant for people using mbox files -->
          <!-- with systems such as mail list archive displayers -->
          <!-- Note that dot-locking is not currently supported -->
          <!-- so network (write) accesses may cause mbox corruption -->
          <!-- the sample mbox URL is an absolute URL; mbox:///var/mail will put the users mbox files in /var/mail/-->
          <!--
          <inboxRepository>
             <repository destinationURL="mbox:///var/mail/" type="MAIL"/>
          </inboxRepository>
          -->
       </James>
       <!-- Fetch pop block, fetches mail from POP3 servers and inserts it into the incoming spool -->
       <!-- Warning: It is important to prevent mail from looping by setting the  -->
       <!-- fetched domains in the <servernames> section of the <James> block     -->
       <!-- above. This block is disabled by default.                             -->
       <!-- FetchPOP is being deprecated in favor of FetchMail                    -->
        <fetchpop enabled="true">
            <!-- You can have as many fetch tasks as you want, but each must have a -->
            <!-- unique name by which it identified -->
            <fetch name="mydomain.com">
                <!-- Host name or IP address -->
                <host>mail.mydomain.com</host>
                <!-- Account login username -->
                <user>username</user>
                <!-- Account login password -->
                <password>pass</password>
                <!-- How frequently this account is checked - in milliseconds. 600000 is every ten minutes -->
                <interval>600000</interval>
            </fetch>
        </fetchpop>
        <!-- This is an example configuration for FetchMail, a JavaMail based gateway  -->
        <!-- service that pulls messages from other sources, and inserts them into the -->
        <!-- spool.  They are then processed normally, although FetchMail generally    -->
        <!-- has to fabricate some of the envelope information.  FetchMail should be   -->
        <!-- considered a mail gateway, rather than a relay, in RFC terms.             -->
        <!-- Fetchmail is a functionally richer replacement for FetchPOP.              -->
        <!-- CHECKME: FetchMail is disabled by default, and must be configured to use. -->
        <!-- Edit the file referred to by fetchmailConfig to enable and configure.     -->
        &fetchmailConfig;
       <!-- The James Spool Manager block  -->
       <!-- -->
       <!-- This block is responsible for processing messages on the spool. -->
       <spoolmanager>
          <!-- Number of spool threads -->
          <threads> 10 </threads>
          <!-- Set the Java packages from which to load mailets and matchers -->
          <mailetpackages>
             <mailetpackage>org.apache.james.transport.mailets</mailetpackage>
          </mailetpackages>
          <matcherpackages>
             <matcherpackage>org.apache.james.transport.matchers</matcherpackage>
          </matcherpackages>
          <!-- The root processor is a required processor - James routes all mail on the spool -->
          <!-- through this processor first. -->
          <!-- -->
          <!-- This configuration is a sample configuration for the root processor. -->
          <processor name="root">
             <!-- Checks that the email Sender is associated with a valid domain. -->
             <!-- Useful for detecting and eliminating spam. -->
             <!-- For this block to function, the spam processor must be configured. -->
             <!--
             <mailet match="SenderInFakeDomain=64.55.105.9,64.94.110.11,194.205.62.122,194.205.62.62,195.7.77.20,206.253.214.102,212.181.91.6,219.88.106.80,194.205.62.42,216.35.187.246,203.119.4.6" class="ToProcessor">
                <processor> spam </processor>
             </mailet>
             -->
             <!-- Important check to avoid looping -->
             <mailet match="RelayLimit=30" class="Null"/>
             <!--
             <mailet match="All" class="XMLVirtualUserTable">
                <!- 1:1 mapping ->
                <mapping>morgoth@middle-earth=sauron@mordor</mapping>
                <!- 1:n mapping ->
                <mapping>istari@middle-earth=saruman@isengard;radigast;gandalf</mapping>
                <!- DSN mapping ->
                <mapping>boromir@osgilliath=error:550 Requested action not taken: no such user here</mapping>
                <!- regex based mapping ->
                <mapping>*@osgilliath=regex:(.*)@osgilliath:${1}@minas-tirith</mapping>
                <!- both standard and regex mapping ->
                <mapping>ring@*=onering@mordor;regex:ring@(.*):ring@${1}</mapping>
                <!- conditional regex mapping example ->
                <mapping>*@listserver=regex:(.*)-on@listserver:${1}-subscribe@listserver;
                                      regex:(.*)-off@listserver:${1}-unsubscribe@listserver
                </mapping>
             </mailet>
             -->
             <!-- White List:
                  If you use block lists, you will probably want to check
                  for known permitted senders.  This is particularly true
                  if you use more aggressive block lists, such as SPEWS,
                  that are prone to block entire subnets without regard
                  for non-spamming senders.
              -->
             <!-- specific known senders -->
             <!--
             <mailet match="SenderIs=goodboy@goodhost"
                     class="ToProcessor">
                <processor> transport </processor>
             </mailet>
             -->
             <!-- People on this list agree to pay a penalty if they send spam -->
             <mailet match="InSpammerBlacklist=query.bondedsender.org"
                     class="ToProcessor">
               <processor> transport </processor>
             </mailet>
             <!-- E-mail legally required not to be spam (see: http://www.habeas.com) -->
             <!--
             <mailet match="HasHabeasWarrantMark" class="ToProcessor">
                <processor> transport </processor>
             </mailet>
             -->
             <!-- End of White List -->
             <!-- Check for delivery from a known spam server -->
             <!-- This set of matchers/mailets redirect all emails from known -->
             <!-- black holes, open relays, and spam servers to the spam processor -->
             <!-- For this set to function properly, the spam processor must be configured. -->
             <mailet match="InSpammerBlacklist=dnsbl.njabl.org"
                     class="ToProcessor">
               <processor> spam </processor>
               <notice>550 Requested action not taken: rejected - see http://njabl.org/ </notice>
             </mailet>
             <mailet match="InSpammerBlacklist=relays.ordb.org"
                     class="ToProcessor">
               <processor> spam </processor>
               <notice>550 Requested action not taken: rejected - see http://www.ordb.org/ </notice>
             </mailet>
             <!-- Sample matching to kill a message (send to Null) -->
             <!--
             <mailet match="RecipientIs=badboy@badhost" class="Null"/>
             -->
             <!-- Send remaining mails to the transport processor for either local or remote delivery -->
             <mailet match="All" class="ToProcessor">
                <processor> transport </processor>
             </mailet>
          </processor>
          <!-- The error processor is required.  James may internally set emails to the -->
          <!-- error state.  The error processor is generally invoked when there is an -->
          <!-- unexpected error either in the mailet chain or internal to James. -->
          <!-- -->
          <!-- By default configuration all email that generates an error in placed in -->
          <!-- an error repository. -->
          <processor name="error">
             <!-- If you want to notify the sender their message generated an error, uncomment this       -->
             <!--
             <mailet match="All" class="Bounce"/>
             -->
             <!-- If you want to notify the postmaster that a message generated an error, uncomment this  -->
             <!--
             <mailet match="All" class="NotifyPostmaster"/>
             -->
             <!-- Logs any messages to the repository specified -->
             <mailet match="All" class="ToRepository">
                <repositoryPath> file://var/mail/error/</repositoryPath>
                <!-- An alternative database repository example follows. -->
                <!--
                <repositoryPath> db://maildb/deadletter/error </repositoryPath>
                -->
             </mailet>
          </processor>
          <!-- Processor CONFIGURATION SAMPLE: transport is a sample custom processor for local or -->
          <!-- remote delivery -->
          <processor name="transport">
            <!-- This is an example configuration including configuration for a list server. -->
            <!-- CHECKME: before uncommenting this, edit the configuration file's contents   -->
            <!--
              &listserverConfig;
            -->
             <!-- Is the recipient is for a local account, deliver it locally -->
             <mailet match="RecipientIsLocal" class="LocalDelivery"/>
             <!-- If the host is handled by this server and it did not get -->
             <!-- locally delivered, this is an invalid recipient -->
             <mailet match="HostIsLocal" class="ToProcessor">
                <processor> local-address-error </processor>
                <notice>550 - Requested action not taken: no such user here</notice>
             </mailet>
    <!-- CHECKME! -->
             <!-- This is an anti-relay matcher/mailet combination -->
             <!-- -->
             <!-- Emails sent from servers not in the network list are  -->
             <!-- rejected as spam.  This is one method of preventing your -->
             <!-- server from being used as an open relay.  Make sure you understand -->
             <!-- how to prevent your server from becoming an open relay before -->
             <!-- changing this configuration. See also <authorizedAddresses> in SMTP Server -->
             <!-- -->
             <!-- This matcher/mailet combination must come after local delivery has -->
             <!-- been performed.  Otherwise local users will not be able to receive -->
             <!-- email from senders not in this remote address list. -->
             <!-- -->
             <!-- If you are using this matcher/mailet you will probably want to -->
             <!-- update the configuration to include your own network/addresses.  The -->
             <!-- matcher can be configured with a comma separated list of IP addresses  -->
             <!-- wildcarded IP subnets, and wildcarded hostname subnets. -->
             <!-- e.g. "RemoteAddrNotInNetwork=127.0.0.1, abc.de.*, 192.168.0.*" -->
             <!-- -->
             <!-- If you are using SMTP authentication then you can (and generally -->
             <!-- should) disable this matcher/mailet pair. -->
             <mailet match="RemoteAddrNotInNetwork=127.0.0.1" class="ToProcessor">
                <processor> relay-denied </processor>
                <notice>550 - Requested action not taken: relaying denied</notice>
             </mailet>
             <!-- Attempt remote delivery using the specified repository for the spool, -->
             <!-- using delay time to retry delivery and the maximum number of retries -->
             <mailet match="All" class="RemoteDelivery">
                <outgoing> file://var/mail/outgoing/ </outgoing>
                <!-- alternative database repository example below -->
                <!--
                <outgoing> db://maildb/spool/outgoing </outgoing>
                -->
                <!-- Delivery Schedule based upon RFC 2821, 4.5.4.1 -->
                <!-- 5 day retry period, with 4 attempts in the first
                     hour, two more within the first 6 hours, and then
                     every 6 hours for the rest of the period. -->
                <delayTime>  5 minutes </delayTime>
                <delayTime> 10 minutes </delayTime>
                <delayTime> 45 minutes </delayTime>
                <delayTime>  2 hours </delayTime>
                <delayTime>  3 hours </delayTime>
                <delayTime>  6 hours </delayTime>
                <maxRetries> 25 </maxRetries>
                <!-- The number of threads that should be trying to deliver outgoing messages -->
                <deliveryThreads> 1 </deliveryThreads>
                <!-- If false the message will not be sent to given server if any recipients fail -->
                <sendpartial>false</sendpartial>
                <!-- A single mail server to deliver all outgoing messages. -->
                <!-- This is useful if this server is a backup or failover machine, -->
                <!-- or if you want all messages to be routed through a particular mail server, -->
                <!-- regardless of the email addresses specified in the message -->
                <!-- -->
                <!-- The gateway element specifies the gateway SMTP server name. -->
                <!-- If your gateway mail server is listening on a port other than 25, -->
                <!-- you can set James to connect to it on that port using the gatewayPort -->
                <!-- element. -->
                <!-- Although normally multiple addresses are implemented through proper -->
                <!-- DNS configuration, the RemoteDelivery mail does allow specifying -->
                <!-- multiple gateway elements, each of which may also have a port -->
                <!-- e.g., mygateway:2525 -->
                <!-- the gatewayPort element is used as a default -->
                <!--
                <gateway> mytrans-port.com</gateway>
                <gatewayPort>25</gatewayPort>
                -->
             </mailet>
          </processor>
          <!-- Processor CONFIGURATION SAMPLE: spam is a sample custom processor for handling -->
          <!-- spam. -->
          <!-- You can either log these, bounce these, or just ignore them. -->
          <processor name="spam">
             <!-- To destroy all messages, uncomment this matcher/mailet configuration -->
             <!--
             <mailet match="All" class="Null"/>
             -->
             <!-- To notify the sender their message was marked as spam, uncomment this matcher/mailet configuration -->
             <!--
             <mailet match="All" class="Bounce"/>
             -->
             <!-- To notify the postmaster that a message was marked as spam, uncomment this matcher/mailet configuration -->
             <!--
             <mailet match="All" class="NotifyPostmaster"/>
             -->
             <!-- To log the message to a repository, this matcher/mailet configuration should be uncommented. -->
             <!-- This is the default configuration. -->
             <mailet match="All" class="ToRepository">
                <repositoryPath>file://var/mail/spam/</repositoryPath>
                <!-- Changing the repositoryPath, as in this commented out example, will -->
                <!-- cause the mails to be stored in a database repository.  -->
                <!-- Please note that only one repositoryPath element can be present for the mailet -->
                <!-- configuration. -->
                <!--
                <repositoryPath> db://maildb/deadletter/spam </repositoryPath>
                -->
             </mailet>
          </processor>
          <!-- This processor handles messages that are for local domains, where the user is unknown -->
          <processor name="local-address-error">
             <!-- To notify the sender the address was invalid, uncomment this matcher/mailet configuration -->
             <!-- The original message is not attached to keep the bounce processor from deliverying spam -->
             <!--
             <mailet match="All" class="Bounce">
                <attachment>none</attachment>
             </mailet>
             -->
             <!-- To notify the postmaster that a message had an invalid address, uncomment this matcher/mailet configuration -->
             <!--
             <mailet match="All" class="NotifyPostmaster"/>
             -->
             <mailet match="All" class="ToRepository">
                <repositoryPath> file://var/mail/address-error/</repositoryPath>
                <!-- An alternative database repository example follows. -->
                <!--
                <repositoryPath> db://maildb/deadletter/address-error </repositoryPath>
                -->
             </mailet>
          </processor>
          <!-- This processor handles messages that are for foreign domains, where relaying is denied -->
          <!-- As of James v2.2, this processor can be deprecated by using the <authorizedAddresses> tag
               in the SMTP Server, and rejecting the message in the protocol transaction.  -->
          <processor name="relay-denied">
             <!-- To notify the sender the address was invalid, uncomment this matcher/mailet configuration -->
             <!-- The original message is not attached to keep the bounce processor from deliverying spam -->
             <!--
             <mailet match="All" class="Bounce">
                <attachment>none</attachment>
             </mailet>
             -->
             <!-- To notify the postmaster that a relay request was denied, uncomment this matcher/mailet configuration -->
             <!--
             <mailet match="All" class="NotifyPostmaster"/>
             -->
             <mailet match="All" class="ToRepository">
                <repositoryPath>file://var/mail/relay-denied/</repositoryPath>
                <!-- An alternative database repository example follows. -->
                <!--
                <repositoryPath> db://maildb/deadletter/relay-denied </repositoryPath>
                -->
             </mailet>
          </processor>
       </spoolmanager>
       <!-- DNS Server Block -->
       <!-- -->
       <!-- Specifies DNS Server information for use by various components inside -->
       <!-- James. -->
       <!-- -->
       <!-- If autodiscover is true, James will attempt to autodiscover the DNS servers configured on your underlying system.-->
       <!-- Currently, this works if the OS has a unix-like /etc/resolv.conf,-->
       <!-- or the system is Windows based with ipconfig or winipcfg.-->
       <!-- -->
       <!-- If no DNS servers are found and you have not specified any below, 127.0.0.1 will be used-->
       <!-- If you use autodiscover and add DNS servers manually a combination of all the dns servers will be used  -->
       <!--  -->
       <!-- Information includes a list of DNS Servers to be used by James.  These are -->
       <!-- specified by the server elements, each of which is a child element of the -->
       <!-- servers element.  Each server element is the IP address of a single DNS server. -->
       <!-- The servers element can have multiple server children. -->
       <dnsserver>
          <servers>
             <!--Enter ip address of your DNS server, one IP address per server -->
             <!-- element. -->
             <!--
              <server>216.251.32.100</server>
             -->
          </servers>
          <!-- Change autodiscover to false if you would like to turn off autodiscovery -->
          <!-- and set the DNS servers manually in the <servers> section -->
          <autodiscover>true</autodiscover>
          <authoritative>false</authoritative>
       </dnsserver>
       <remotemanager>
          <port>4555</port>
          <!--  Uncomment this if you want to bind to a specific inetaddress -->
          <!--
          <bind> </bind>
          -->
          <!--  Uncomment this if you want to use TLS (SSL) on this port -->
          <!--
          <useTLS>true</useTLS>
          -->
          <handler>
             <!-- This is the name used by the server to identify itself in the RemoteManager -->
             <!-- protocol.  If autodetect is TRUE, the server will discover its -->
             <!-- own host name and use that in the protocol.  If discovery fails, -->
             <!-- the value of 'localhost' is used.  If autodetect is FALSE, James -->
             <!-- will use the specified value. -->
             <helloName autodetect="true">myMailServer</helloName>
             <administrator_accounts>
    <!-- CHECKME! -->
                <!-- Change the default login/password. -->
                <account login="username" password="password"/>
             </administrator_accounts>
             <connectiontimeout> 60000 </connectiontimeout>
          </handler>
       </remotemanager>
        <!-- The POP3 server is enabled by default -->
        <!-- Disabling blocks will stop them from listening, -->
        <!-- but does not free as many resources as removing them would -->
       <pop3server enabled="true">
          <!-- port 995 is the well-known/IANA registered port for POP3S  ie over SSL/TLS -->
          <!-- port 110 is the well-known/IANA registered port for Standard POP3 -->
          <port>110</port>
          <!-- Uncomment this if you want to bind to a specific inetaddress -->
          <!--
          <bind> </bind>
          -->
          <!--  Uncomment this if you want to use TLS (SSL) on this port -->
          <!--
          <useTLS>true</useTLS>
          -->
          <handler>
             <!-- This is the name used by the server to identify itself in the POP3 -->
             <!-- protocol.  If autodetect is TRUE, the server will discover its -->
             <!-- own host name and use that in the protocol.  If discovery fails, -->
             <!-- the value of 'localhost' is used.  If autodetect is FALSE, James -->
             <!-- will use the specified value. -->
             <helloName autodetect="true">myMailServer</helloName>
             <connectiontimeout>120000</connectiontimeout>
          </handler>
       </pop3server>
        <!-- The SMTP server is enabled by default -->
        <!-- Disabling blocks will stop them from listening, -->
        <!-- but does not free as many resources as removing them would -->
       <smtpserver enabled="true">
          <!-- port 25 is the well-known/IANA registered port for SMTP -->
          <port>25</port>
          <!-- Uncomment this if you want to bind to a specific inetaddress -->
          <!--
          <bind> </bind>
          -->
          <!-- Uncomment this if you want to use TLS (SSL) on this port -->
          <!--
          <useTLS>true</useTLS>
          -->
          <handler>
             <!-- This is the name used by the server to identify itself in the SMTP -->
             <!-- protocol.  If autodetect is TRUE, the server will discover its -->
             <!-- own host name and use that in the protocol.  If discovery fails, -->
             <!-- the value of 'localhost' is used.  If autodetect is FALSE, James -->
             <!-- will use the specified value. -->
             <helloName autodetect="true">myMailServer</helloName>
             <connectiontimeout>360000</connectiontimeout>
             <!--  Uncomment this if you want to require SMTP authentication. -->
             <!--
             <authRequired>true</authRequired>
             -->
    <!-- CHECKME! -->
             <!--  Uncomment this if you want to authorize specific addresses/networks.
                   If you use SMTP AUTH, addresses that match those specified here will
                   be permitted to relay without SMTP AUTH.  If you do not use SMTP
                   AUTH, and you specify addreses here, then only addresses that match
                   those specified will be permitted to relay.
                   Addresses may be specified as a an IP address or domain name, with an
                   optional netmask, e.g.,
                   127.*, 127.0.0.0/8, 127.0.0.0/255.0.0.0, and localhost/8 are all the same
                   See also the RemoteAddrNotInNetwork matcher in the transport processor.
                   You would generally use one OR the other approach.
             -->
             <authorizedAddresses>127.0.0.0/8</authorizedAddresses>
             <!--  Uncomment this if you want to verify sender addresses, ensuring that -->
             <!--  the sender address matches the user who has authenticated. -->
             <!--  This prevents a user of your mail server from acting as someone else -->
             <!--
             <verifyIdentity>true</verifyIdentity>
             -->
             <!--  This sets the maximum allowed message size (in kilobytes) for this -->
             <!--  SMTP service. If unspecified, the value defaults to 0, which means no limit. -->
             <maxmessagesize>0</maxmessagesize>
          </handler>
       </smtpserver>
        <!-- The NNTP server is enabled by default -->
        <!-- Disabling blocks will stop them from listening, -->
        <!-- but does not free as many resources as removing them would -->
        <!-- NNTP-specific: if you disable the NNTP Server, you should also set the nntp-repository's
             threadCount to 0, otherwise there will be threads active and polling  -->
       <nntpserver enabled="true">
       <!-- THE NNTP PROTOCOL IS EXPERIMENTAL AND NOT AS WELL TESTED AS SMTP AND POP3 IN THIS RELEASE.
            The James project recommends that you check the James web site for updates to the NNTP
            service.  -->
          <!-- port 563 is the well-known/IANA registered port for NNTP over SSL/TLS -->
          <!-- port 119 is the well-known/IANA registered port for Standard NNTP -->
          <port>119</port>
          <!-- Uncomment this if you want to bind to a specific inetaddress -->
          <!--
          <bind> </bind>
          -->
          <!-- Uncomment this if you want to use TLS (SSL)  on this port -->
          <!--
          <useTLS>true</useTLS>
          -->
          <handler>
             <!-- This is the name used by the server to identify itself in the NNTP -->
             <!-- protocol.  If autodetect is TRUE, the server will discover its -->
             <!-- own host name and use that in the protocol.  If discovery fails, -->
             <!-- the value of 'localhost' is used.  If autodetect is FALSE, James -->
             <!-- will use the specified value. -->
             <helloName autodetect="true">myMailServer</helloName>
             <co                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                

    hi
    you have to change the config.xml to allow the server accept relay mails from your host machine from which you are sendign the mail ...
    ie
    change
    <mailet match="RemoteAddrNotInNetwork=127.0.0.1" class="ToProcessor">
    <processor> relay-denied </processor>
    <notice>550 - Requested action not taken: relaying denied</notice>
    </mailet>
    add few more ips (your network / subnet ip)
    so that it accpets mails from that machine to be relayed ...
    you can also change the smtp autheriZation part and do that ...
    any one is enough ..
    Regards
    Venkat

  • Various E Mail problems: Junk Mail, Log Off, etc

    I am having various and frustrating problems that are intermittant.
    I have two incoming e mail accounts, one is IMAP and one is POP.
    1. Junk Mail. After having reset my junk mail settings as advised on this site just a few days ago, I am continuing to experience this problem. Messages that the systems "knows" is Junk Mail do NOT go to Junk Mail folder, but to the regular In box. It knows they are Junk Mail because the Tab for changing the message at top of screen says "Not Junk", which means it thinks it is JUNK. They why won't it go into Junk Mail folder?
    2. When I try to delete these messages one by one in In box, the computer "freezes" and takes forever to delete the messages. The In box counter on left hand side of the screen does not decrease as I delete messages, but takes a long time (minutes) to catch up with the deletions.
    3. When receiving certain e mail from specific recipients, the system intermittantly says "message not dowloaded from server, you need to take this account on line". Well. it IS online! Again, this does not happen all the time, but often enough and from the same e mail recipients) that it is very frustrating.
    4. Oftentimes when I try to shut down, I get the dreaded spinning color wheel, only to have to force quit. This is a lengthy process, and then I lose all of the deletions that I have tried to make to my Inbox.
    Are all of these problems somehow related? Cumulatively, they are very frustrating. I never had these kinds of issues with Windows Mail apps. Uuughh!
    Thanks for reading and any assistance.

    There appears to be a problem with the index.
    Verify/repair the startup disk (not just permissions), as described here:
    The Repair functions of Disk Utility: what's it all about?
    After having fixed all the filesystem issues, if any, and ensuring that there’s enough space available on the startup disk (a few GB, plus the space needed to make a backup copy of the Mail folder), try this:
    1. Quit Mail if it’s running.
    2. In the Finder, go to ~/Library/Mail/. Make a backup copy of this folder, just in case something goes wrong, e.g. by dragging it to the Desktop while holding the Option (Alt) key down. This is where all your mail is locally stored.
    3. Locate Envelope Index and move it to the Trash. If you see any other “Envelope Index”-named file there, delete it as well.
    4. Move the “IMAP-” account folder to the Trash. Note that you can do this with IMAP-type accounts because they store mail on the server and Mail can easily re-create them. DON’T trash any “POP-” account folders, as that would cause all mail stored there to be lost.
    5. Open Mail. It will tell you that your mail needs to be “imported”. Click Continue and Mail will proceed to re-create Envelope Index — Mail says it’s “importing”, but it just re-creates the index if the mailboxes are already in Mail 2.x format.
    6. As a side effect of having removed the IMAP account folder, that accounts may be in an “offline” state now. Do Mailbox > Go Online to bring it back online.
    Note: For those not familiarized with the ~/ notation, it refers to the user’s home folder. That is, ~/Library is the Library folder within the user’s home folder, i.e. /Users/username/Library.
    <hr>
    If the problem persists, what are your Preferences > Accounts > Mailbox Behaviors > Junk settings, particularly for the IMAP account?
    Also, what have you done to “reset [your] junk mail settings as advised on this site”? This is what I’d suggest:
    1. Go to Preferences > Junk Mail, disable junk mail filtering, then enable it again. This resets the rule that governs what the junk filter does.
    2. Choose either Training or Automatic mode (it doesn’t matter) and leave the other options checked. Click Advanced to see how the junk filter rule is defined now if you want, but don’t touch anything there.
    3. Reset the junk filter database (Preferences > Junk Mail > Reset).
    4. Open Window > Previous Recipients and get rid of any addresses that you don’t want Mail to treat as legit.

  • Cannot delete item from junk mail folder in iPad?

    Some items cannot be deleted from junk mail folder on iPad 2. It will not move to trash.

    Have you tried swiping across the message in the preview pane when you open the junk folder instead of opening the email and trying to use the trash can icon?
    If that will not work either, try rebooting your iPad and then see if you can delete the junk mail.
    Reboot the iPad by holding down on the sleep and home buttons at the same time for about 10-15 seconds until the Apple Logo appears - ignore the red slider if it appears on the screen - let go of the buttons. Let the iPad start up.

Maybe you are looking for