Message that locks java

Hello
Last week we found that our smtp (James java server) was using a lot of CPU
after several days trying to identify the problem we found a japanese message that was causing the problem. We have a custom mailet that includes a SPAM string in the subject of the message, whem
we try to do that in this message the thread starts eating all the CPU
and locks the problem occours whem I try to get the subject line with
getSubject()
I have created a little program that simulates the problem
import javax.mail.internet.MimeMessage;
import java.io.*;
import javax.mail.*;
import javax.*;
import javax.mail.internet.*;
import javax.activation.*;
import java.util.Properties;
import java.util.Date;
class ts { 
public static void main (String[] args) throws Exception {   
Properties properties = System.getProperties();
Session session = Session.getInstance(properties, null);
FileInputStream fis = new FileInputStream("badmsg.txt");
MimeMessage c = new MimeMessage(session, fis);
System.out.println("Hello");
String teste = c.getSubject();
System.out.println("MSG:"+ test );
you can create a file named badmsg.txt with the following test message
Subject: [Weekly Mag2 2004/01/28 =?ISO-2022-JP?B?GyRCJWElLCVNISYbKEI=?=
        =?ISO-2022-JP?B?GyRAGyRCJTMlcyU/JS8lSCQsSVRNVyRLISkyd0UsQDgzaCRPJDkbKEI=?=
        =?ISO-2022-JP?B?GyRAGyRCJDAkPSQzISobKEI=?=]
Test
Any idea how to solve this We are using Linux with
java version "1.4.2-rc1"Java(TM) 2 Runtime Environment, Standard Edition (buildBlackdown-1.4.2-rc1)Java HotSpot(TM) Client VM (build Blackdown-1.4.2-rc1, mixed mode)

I found I way to solve this problem
instead of using getSubject I use getHeader(�subject�,null)

Similar Messages

  • HT3633 I have an error message that reads: java.lang.noclassdefFounder - need to fix can anyone help?

    I have an error message that reads: java.lang.noclassdefFounder - need to fix can anyone help?

    That's a bug in whatever Java program you're running.
    That's not an error specific to OS X.
    (There's usually a whole lot more text dumped by Java, too.)
    Check with whoever wrote or is supporting the package you're working with.

  • HT1338 I'm getting a message that my Java is not updated, but when I run the update check, I'm told all is updated. Some web materials won't open because my Java is not updated. What do I do?

    I'm getting a message that my Java is not updated, but when I run the update check, I'm told all is updated. Some web materials won't open because my Java is not updated. What do I do?

    Hi Ginny,
    There are no more updates for Java from Apple for 10.5.8, the only way to get a Java upgrade is updating your OSX.
    Snow Leopard/10.6.x Requirements...
    General requirements
       * Mac computer with an Intel processor
        * 1GB of memory (I say 4GB at least, more if you can afford it)
        * 5GB of available disk space (I say 30GB at least)
        * DVD drive for installation
        * Some features require a compatible Internet service provider; fees may apply.
        * Some features require Apple’s MobileMe service; fees and terms apply.
    Which apps work with Mac OS X 10.6?...
    http://snowleopard.wikidot.com/
    It looks like they do still have it:
    http://store.apple.com/us/product/MC573Z/A?fnode=MTY1NDAzOA
    And it's been reported that if you have a MobileMe account Apple will send one free.

  • I'm trying to download Firefox 4 onto Windows 7 platform. I keep getting an error message that says Java script has an error in Chrome ? Unable to complete download. Constant ahngs & freezes

    I am running on Windows 7 platform. I tired to download the latest Firefox 4 release. Each time, I get the message that "there is an error on line 20 in Java script Chrome that is preventing the download from continuing. I've run Fox in safe mode & still get the same message.

    Your More system details list shows that you use Firefox 4:
    *Mozilla/5.0 (Windows NT 6.1; rv:2.0) Gecko/20100101 Firefox/4.0
    Are you trying to (re)install Firefox 4 or do you get that error if you start Firefox?
    Do a clean (re-)install:
    * Download a fresh Firefox copy and save the file to the desktop.
    * Firefox 4.0: http://www.mozilla.com/firefox/all.html
    * Uninstall your current Firefox version and remove the Firefox program folder before installing that copy of the Firefox installer.
    * Don't remove personal data if you uninstall the current version.
    * It is important to delete the Firefox program folder to remove all the files and make sure that there are no problems with files that were leftover after uninstalling.
    Your bookmarks and other profile data are stored elsewhere (not in the Firefox program folder) and won't be affected by a reinstall, but make sure that you do not select to remove personal data if you uninstall Firefox.
    If that still doesn't work then create a new profile as well.
    See [[Basic Troubleshooting#Make_a_new_profile|Basic Troubleshooting: Make a new profile]]
    If that new profile works then you can transfer some files from the old profile to that new profile (be careful not to copy corrupted files)
    * http://kb.mozillazine.org/Transferring_data_to_a_new_profile_-_Firefox

  • HipServ for STORA gives error Message that the Java plugin requires a newer version than 3.0. I have installed 4.0, so how come?

    HipServ for STORA by Netgear: when I start it there is an error message "The new JAVA plugin requires a Foxfire version 3 or later". the version of Foxfire I have installed is 4.0. I delete the error message and the HipServ program goes on and works perfectly. To whom should I direct my question, which is how to get rid of the error message? I can't seem to find any new driver for the STORA backup device (RAID 1 pair of 1 tByte drives on LAN)

    Hi rctbone,
    The problem is not with Firefox, but with the Java update. A solution can be found here: http://forum1.netgear.com/showthread.php?t=59935&highlight=java+plugin
    Cheers,
    Roby!

  • Ever since I downloaded FF's v6, everytime I go to YouTube and open a video, I get an error message that says: "[Java Script Application] Error: Div is null" How do I fix this problem?

    If I go to YouTube, no matter what video I click on to watch, the error message "[Java Script Application] Error: Div is null" pops up. It started happening right after I updated to FF v6. I also have installed the latest version of Java. I submitted this question a few weeks ago, but never received a reply.
    Thanks for any help you can provide to fix this.
    Scott Cromwell
    [email protected]

    hello, can you try to replicate this behaviour when you launch firefox in safe mode once? if not, maybe an addon is interfering here...
    [[Troubleshoot extensions, themes and hardware acceleration issues to solve common Firefox problems]]

  • HT4623 I did the latest update to my i pad 2 and now Safari does not work properly . I get messages that the java script needs to be turned on which I did. How do I get this all back after this update?

    I did the latest update to my I pad 2 and lost Safari . I was instructed to switch the Java script on which I did but Safari is still not working properly . how do I get everything back after this software update.

    Try a reset: hold down the home button along with the power button until you see the Apple, then let go.

  • When I open my iMac I keep getting messages that say Java Runtime Environment details and instal

    I updated to Yosemite and now whenever I open up my IMac it says Java Runtime Environment needs to be installed and you can either select ok or details and not sure what to do about it.

    Most likely, you have either the Facebook video calling plugin or the "NexDef" plugin for watching baseball streams. Both depend on the Java runtime distributed by Apple. If you no longer need the plugin, remove it. Otherwise, install Java.

  • Local storage message that locks up

    Using a program downloaded onto my Mac: Ouino French v 2.5
    After taking quizzes (which stores results using Flash),  the following message comes up
    None of the buttons work, and the Ouino French freezes. I have the latest Flash Player 13.0.0.214. Operating system is Mac OSX 10.9.3.
    I have tried resetting Local's storage in Flash's preferences to "ask me" which was the setting I used anyway, then to "Always" for Local (only) and restarting after each change. I still get the same problem.

    Perhaps his link helps  you 
    http://www.mssqltips.com/sqlservertip/1909/how-to-configure-password-enforcement-options-for-standard-sql-server-logins/
    Best Regards,Uri Dimant SQL Server MVP,
    http://sqlblog.com/blogs/uri_dimant/
    MS SQL optimization: MS SQL Development and Optimization
    MS SQL Consulting:
    Large scale of database and data cleansing
    Remote DBA Services:
    Improves MS SQL Database Performance
    SQL Server Integration Services:
    Business Intelligence

  • Trying to upload some photos to an e-mail an I get a message that says "The iPhoto Library is locked, on a locked disk, or you do not have permission to make changes to it."  To where do I navigate to unlock this so I can have access to my photo library?

    Trying to upload some photos to an e-mail an I get a message that says "The iPhoto Library is locked, on a locked disk, or you do not have permission to make changes to it."  To where do I navigate to unlock this so I can have access to my photo library?

    Couple of things to try:
    Restart your mac and try launch iPhoto again.
    If that fails:
    Go to your Pictures Folder and find the iPhoto Library there. Right (or Control-) Click on the icon and select 'Show Package Contents'. A finder window will open with the Library exposed.
    Look there for a file called ‘iPhoto’Lock.data or similar. Drag it to the Desktop. Make no other changes. Start iPhoto. Does that help?
    If not: Where is your iPhoto Library stored? If it's on an External Disk, what format is that?

  • I've been receiving an error message, "That the .itl file is locked, on a locked disc or you do not have write permission". Can someone tell me how to unlock the file or disc?

    I've been receiving an error message, "That the .itl file is locked, on a locked disc or you do not have write permission". Can someone tell me how to unlock the file or disc?

    theres no - in "itunes" its all one word
    try right clicking and running itunes as adminstrator or try on a different user account

  • I have iPhone 5 IOS 8.1.2; for past 13 weeks I get message that my phone has not backed up on the cloud. Every night however the wifi is on, phone is connected to power, and screen is locked. Any idea why back-up is not happening ?

    I have an iPhone 5 IOS 8.1.2;
    for the past 13 weeks I get the message that "this phone has not been backed up on the cloud". However, every night it is connected to wifi, phone is connected to power, and the screen is locked. Any idea why back-up is not happening ? By the way, I do not have the "back up now" option in Setting / iCloud.. Help anyone ?

    Try deleting an other icloud backup and see if it will automatically backup.

  • Trying to discard an app into TRASH and I receive a message that "app cannot be removed because it is locked."  How can I unlock an app???

    Trying to discard an app into TRASH and I receive a message that "app cannot be removed because it is locked."  How can I unlock an app???

    Something may have corrupted your User account permissions. Whatever it was that did that is likely to do it again, and will require further investigation.
    To reset your User account permissions perform the following. It may not fix the problem but it will not make it any worse:
    Boot OS X Recovery by holding ⌘ and r (two fingers) while you start your Mac.
    When the Mac OS X Utilities screen appears, select Utilities > Terminal.
    In the Terminal window type resetpassword and press Enter. A window will open behind Terminal that looks like this:
    Do not enter a new password.
    Select your startup volume at the top. From the dropdown below it, select the user account with the problem.
    At the bottom of the window, you will see Reset Home Directory Permissions and ACLs.
    Click the Reset button.
    Quit Reset Password
    Quit Terminal
    Quit OS X Utilities and restart your Mac.
    Back up your system before doing anything else because disk corruption is another possibility that has to be considered.

  • My Ipad is locked and display a message that says " The Ipad hasnt been backed up in 2 weeks...........connected to wifi".  How do I come out of it?

    My Ipad is locked and display a message that says " The Ipad hasnt been backed up in 2 weeks...........connected to wifi".  How do I come out of it?

    Reset iPad
    Hold down the Sleep/Wake button and the Home button at the same time for at least ten seconds, until the Apple logo appears
    Note: Data will not be affected.

  • How to disable the message that pops up every time i connect my iphone "photos in the camera roll of iphone cannot be imported because the device is locked with a passcode"?

    Wrongly posted in iPhoto forum, should probably be posted here instead.
    I want to remove the message that pops up every time i connect my IPhone that says: "Photos in the Camera Roll of "Name" cannot be imported because the device is locked with a passcode.".
    This computer is not one that I want to import photos to (or sync with the iPhone), so this message is just very annoying, and it pops up all the time. I cannot find a way to disable this message. It is constantly appearing. No application is launching, I have turned off the iPhoto launch in the Image Capture app as well as in iPhoto. Thanks in advance if anyone has any information about this.

    Because your computer sees your phone, as it would see any digital camera, as long as you have photos in your camera role. Since you state you don't sync with this computer & have a passcode on your phone, that's why you get that message. The only way to prevent that message is either start syncing with this computer; remove the photos from your camera roll prior to connecting; or first turn off your passcode before you connect. Either that, or you live with it.
    You shouldn't be storing photos in your camera roll anyway. iPhone camera roll is not designed for photo storage. You should be regularly importing them.

Maybe you are looking for