I suggest you run Keychain First Aid if you have Panther. It can be found in the Applications folder, under the Utilities folder, and is a feature in Keychain Access (or if you get this: /Applications/Utilities/Keychain Access). (Under the window menu, or just press Command-Option-A when in Keychain Access).
If you are using Jaguar or earlier, delete your keychain, by deleting the file in the Keychain folder found in the Library folder (in your Home folder). Or ~/Library/Keychains/
But for the most part if your keychain is corrupt, other applications will also ask you to enter your password again.
I have done both of these things (secured owner rights on the keychain and run Keychain First Aid in Panther) and I still get the password request from time to time. I did some searching around, and apparently this issue has something to do with going into sleep mode. If anyone comes up with a real fix, let me know too!
It also happens occasionally when Apple has problems with the mail server. It's sometimes wise to just quit Mail and wait a few hours before trying again when the problem usually just goes away.
Your particular situation might not be due to this, but just so you know and don't panic if it is a keychain issue that you solve, and then it mysteriously re-appears for a few hours in the future.
I don't know if it's still a problem, but with some multiuser login systems the non-admin users weren't able to maintain passwords with one particular ISP I had. It wasn't an issue with other ISPs and it went away for me with Jaguar 10.2.8.
Update. After running the first aid, Mail continues to ask for paasword. I am the admin and sole user of the mac so can't be about right s and privileges. Just seems to be happening a little more frequently the last 2-3 days.
This has happened to meet on an irregular basis ever since I switched to the Mail app. and OS X. Sometimes at such a crazy rate of several times a minute, in which case I just shut down Mail for awhile.
I put it down to my ISP (Bell HSE dsl) and don't place much hope on them fixing it. The last time I talked to them was the fall and they were in the middle of a war trying to stop a virus which had swamped their mail servers.
I am just glad the mail arrives and that all these attachments I've been sent since last week don't work on Macs!
I too have had the same problem, but after the last Safari update, a new one has appeared.
I have three e-mail accounts, one .mac and two telus.net.
The mail app always retrieves the .mac mail without fail.
The two telus.net accounts, "donaldjs" and "mybirdie" are configured identical in every way, but mail only retrieves the "mybirdie" mail. It will not retrieve "donaldjs" mail. I have to use my netscape browser to accomplish this feat.
It's a mystery to me, so I just live with it and use two apps.
I've had that happen to me for years on an occasional basis. It's done it when I was using Outlook Express, Entourage, and finally Mail. I don't think it has anything to do with keychain, but rather something to do with the ISP resetting something and needing to be reminded of the setup. Since this is a question that pops up an many forums, and has done so for quite some time, I don't think there's a quick fix that any of us can do.