Can you prevent a block of memory from being swapped?

I'm wondering if there's a way to "lock" a section of memory in Java so that it will not be written out to the swap file by the OS.
Let's say you're writing a client application that will connect to a server, and allow the user (after authentication, of course) to download sensitive information to the client machine and view it. Because the client machine may be in an unsecure environment (i.e. public library terminal, cybercafe, etc), it is desirable to ensure that no trace of the information remains, even in the swap file. The data in question is largely text, so it wouldn't be more than a few hundred KB, therefore I can't imagine it would be a problem to reserve this memory (i.e. it's not like we're starving out other applications running on the same client machine by reserving ALL physical memory).
Basically I'm looking for something in the API that lets me say to the OS: "don't swap out this block of memory, no matter what". Is there a way to do this?
I found this in the bug database but it doesn't sound entirely like what I'm looking for (and it's marked as "will not fix" anyway):
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4852696

The simple answer is "no".
This is a valid concern about the use of crypto libraries in Java.
Because Java has garbage collection, and can copy anything to any memory region during garbage collection, in practice the crypto library writers choose not to bother about non-swapped memory.
Implementing non-swapped memory in some operating systems like Windows is not a simple task: I believe that in Windows you need to write a device driver and a Windows Service, like the "Protected Storage Service" that you can find in Windows. The "Protected Storage" is not very used in Windows - it implements only the CryptEncryptData and CryptDecryptData APIs. The real crypto work is done in normal memory, if you check the CryptoAPI Providers that come with Windows.

Similar Messages

  • How can you prevent the mac book pro from unexpectedly shutting off and beeping three times repeatedly?

    How can you prevent the mac book pro from unexpectedly shutting off and beeping three times repeatedly?

    The three beeps are an indication of a hardware problem. Power On Self-Test Beep Definition - Part 2 - Apple Support

  • How can I prevent my Camera Archive import from being interrupted by timecode breaks?

    I'm trying to create Camera Archives from my old mini-dv tapes. I have a Sony Handycam DCR-TRV22 connected via FireWire. When I start the Camera Archive import process, everything is fine for a while but then the process stops with a message about a break in the timecode preventing the archiving from completing.
    Solutions to this problem I've seen online relied on changing import preferences in Final Cut 7. Unfortunately, I only have Final Cut Pro X and I'm not sure how to control this setting.
    I don't really care about timecodes, I just want to dump the entire tape to disk so I have a backup of the tape but the timecode break is interrupting the process and making me get involved a lot more often during the import process.
    Does anyone know how to force Final Cut Pro X to push through timecode breaks in a Camera Archive import?

    To clarify, this problem is not simply making me get involved more, but is preventing the Camera Archive operation from completing.

  • How can I PREVENT imessages and phone records from being deleted? Its good to be able to block things, but I need to know that no content is being deleted either.

    Restrictions allow the requirement of pass code to deletion of Apps, but not of actual phone content. That is only half the solution - if someone wants to communicate with another person badly enough, they will find a way to create a different user account, phone number, etc.regardless of whether or not the number/person is blocked. I need to see ALL communication and ensure nothing can be deleted without a pass code.

    There is no way to do that. If some one is creating new accounts to communicate with you after you've asked them not to, you have a bigger problem. You may want to talk to your local law enforcement about stalking.

  • How can you stop your ipod touch data from being restored on the computer with a program that lets you see your deleated safari history

    heeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeelllllllllllllllllllllllllllllllllllllppppppp pppppppppppppp

    Delete the backup from iTunes. Go to iTunes>Preferences>Devices and highlight the backup and click on delete. You have to do that after every sync. Also, make sure that you empty the recycle bin (PC) or trash (Mac) to really delete the backup.
    Also, in the future you can turn on Private browsings in Settings>Safari or go there and Clear History right before you sync.

  • HT1541 Can you stop the e-gift card from being purchased

    I just bought a $10 dollar e-gift card for myself and sent it to myself. Did not realize how long it can take, and is can just go to the store tomorrow faster than it arriving. Can I stop the purchase or am I stuck?

    If this page doesn't help then you will need to try contacting iTunes support (you will need to give them the serial number and activation code from the card) : http://www.apple.com/support/itunes/contact/ - click on Contact iTunes Store Support on the right-hand side of the page, then iTunes Cards And Codes

  • Can I prevent a stolen ipod shuffle from being synced with itunes?

    I had my shuffle stolen and it is registered with me.  Can I make sure that the person who stole it can not sync with itunes?
    Thanks,
    Jeff Ryan

    No.
    (99208)

  • Can you control a URL in eloqua from being adding the query string??

    If I am inserting a URL in an email, i cant seem to stop eloqua from adding extra parameters in the form of query string in eloqua.
    I want to make this happen because the URL doesnt seem to work if we add any extra parameter using query string.

    I've tired doing this and it did not work for me. However, I was able to find a solution that helped me a whole lot.
    After running all test runs - I found a solution that helped me take off the extra parameters that Eloqua adds to all URL's.
    I created my urls without placing "http://" or "https://" or http://www." or "https://www." and that helped take off all tracking.
    Re: Use of tinyUrl

  • How can you prevent encrypted folders that you created in disc utility from being deleted?

    How can you prevent encrypted folders that you created in disc utility from being deleted?

    bibst wrote:
    How can you prevent encrypted folders that you created in disc utility
    You cannot create encrypted folders in, or encrypt folders with, Disk Utility.
    You can create with Disk Utility encrypted disk images from folders. I assume that's what you mean.
    The proper way to do it is by setting the immutable bit. Read here
    <http://www.thexlab.com/faqs/immutableflags.html>
    about the immutable bits (and the trouble they sometimes create).
    The user immutable bit (uchg) is the same as the Finder lock, as described above by X423424X. It's a weak lock, with only a warning.
    The system immutable bit (schg) is more powerful. Once is set, the item cannot be deleted in Finder (even though Finder will ask for your password and may give you the impression that it can trash it; it will end with an error).
    I set it in Terminal, thus
    $ sudo chflags schg my_encrypted_disk_image
    and unset it also in Terminal
    $ sudo chflags noschg my_encrypted_disk_image
    (Note that, when you unset the system immutable bit, the change won't be reflected immediately in Finder, but the item can be trashed nevertheless.)

  • Can you prevent Procurement Wizard from popping up when Procurement Documen

    Can you prevent Procurement Wizard from popping up when Procurement Document is checked on the Logistics tab?
    We would like to handle all Procurement Documents in a process separate from entry of the Sales Order. Is there a way to not have the Procurement Wizard pop up automatically when a Sales Order has Procurement Document checked and is then added?
    Alan

    Hi Alan,
    Please check Note No. :1524113. There is a change in working of Procurement Wizard as follows which is mentioned in the Note.
    In the "Customer" window of the procurement confirmation wizard, the "Include All Open Sales Orders" checkbox was added. If you select this checkbox, all open sales orders with unfulfilled purchase quantities for the selected business partners are displayed.
    If you do not select this checkbox, only those sales orders are displayed for which the "Procurement Document" option was checked or that use a drop-ship warehouse and have unfulfilled purchase quantities.
    Check in Demo if you do not tick the checkbox 'Procurement Document' and in the Procurement Confirmation wizard, use the 'Include All Open Sales Orders, whether the same helps.
    Kind Regards,
    Jitin
    SAP Business One Forum Team

  • How can I prevent my new Mac Air from freezing in Safari

    How can I prevent my new Mac Air from freezing in while using Safari?

    Hi nainmom,
    Thanks for visiting Apple Support Communities.
    I recommend starting with these steps if your iPod nano is not recognized by your Mac:
    iPod not recognized in iTunes and Mac desktop
    http://support.apple.com/kb/ts1410
    Best,
    Jeremy

  • HT201269 Can you get your previously purchased ringtones from itunes back when you switch to a new device?

    Can you get your previously purchased ringtones from itunes back when you switch to a new device?

    Try here:
    iTunes: Error 13019 during sync

  • How can you create a writable PDF document from a PPT presentation ?

    How can you create a writable PDF document from a PPT presentation ? Upper part with the image , lower part with a free space in order to take notes for students during presentation or course.
    Thanks.
    B

    You can make a PDF file out of you notes and handouts but using the Adobe PDF printer.
    Open your PowerPoint Document then go to “File” “Print”
    Select ‘Adobe PDF” Printer
    Under slides, select which way you want to print. Note it will not print to a printer but to a PDF file.
    After then go into printer Properties and Setup PDF properties, do the following: (see second image below)
    Default: PDF/A 1-b
    Adobe Security: none (change as needed)
    Adobe Output folder: Prompt for Adobe file name
    Adobe Page size: Letter (change as needed)
    Check the following check boxes
    View Adobe PDf Results,
    Add Document Information,
    Rely on system fonts only,
    Delete Log files for successful jobs.
    Select OK
    A pop will ask you where you want to save the document. The file extension should be PDF. After giving the file name select okay and the file should popup as a PDF. Down side is if you want to speaker notes included then you will have to do another file, like wise with just screen shots then combine into one PDF document.
    I used Acrobat IX Pro. So to do this you need Acrobat IX or X Pro.
    Hope this will help.
    Tiger26

  • Can you share alert and ring tones from iTunes between iPad and iPhone

    Can you share alert and ring tones from iTunes between iPad and iPhone like you can music and movies?

    iOS: Device not recognized in iTunes for Windows

  • Can you send/export a still frame from an FCP sequence?

    Can you send/export a still frame from FCP as a picture to the desktop? Doesn't matter if it is a .jpeg, .tiff, . bitmap
    G5 Mac OS X (10.4.8) Dual 1.8

    serach the forum for any of the hundreds of posts detailing this process -
    my personal favorite is shift-N, apple-9, type name, drag to bin, batch export.
    The best thing about the batch export queue is you can set up a batch with the file format and destination folder and then keep adding new clips/stills to export.
    Hope this helps -
    Max Average

Maybe you are looking for

  • Creative Studio for Home or Business Gone & Poor Printers

    Hello Hp, Extremely disappointed that you've decided to no longer provide creative projects through the Creative Studio for Home or Business.  These products were free and I could print at home.   Snapfish (owned by HP) is very limited in its selecti

  • Apiotek Express Card

    Hello I have the IEEE1394B 800 Firewire Card. When I put it in an icon appears on the top (beside battery level, wireless, clock etc) It gives the option to power off but the other options are faded and I can''t click them. I hook up my soundcard and

  • Adobe iFilter 6 with MS indexing service on asian language

    Hi All: I found the search hit for iFilter 6 on Win2003 (ENG) is much lower than on Win2000 (ENG) with indexing service. (I am testing on Tradition Chinese Characters search). In addition, iFilter is not bundle on Acrobat Reader 8.X, but it show no i

  • Service Offering Catalog list order in Portal

    Is there a way to change the displayorder of Service Offerings in the portal? It does not seem to follow the order of the list set in the console.

  • ID mac-pc problem

    Hello, I need to work on a layout on both Mac and PC, with ID CS2. I did the layout on mac, and when I open it on pc, as I try to save ID crashes. Any ideas where the problem might be? thanks, Markus J