If you have recently cancelled your .Mac/MobileMe subscription, you may be having a problem where your Mac tries to connect to MobileMe and presents a log-in window at random. When this happens, entering the old MobileMe credentials does not work, and clicking cancel seems to be the only way to get rid of the window.