Results 1 to 1 of 1
  1. #1
    JavaLatte is offline Member
    Join Date
    May 2011
    Rep Power

    Default Help reading large files


    I hope you can help me puzzle this newbie conundrum out !

    My eventual goal is to create an RSAPSS digital signature of a file.

    This question specifically relates to the update method prior to calling the sign method.

    As you probably know, update() accepts input of ByteBuffer, byte and byte[].

    I know for a fact that many files I will be dealing with will be quite big (low single digit GB in size). And therefore its a fact I will need to write appropriate code to read the files, otherwise my app will be very slow.

    Looking around the internet, I have found this blog post which suggests either a "FileChannel with a direct ByteBuffer and array reads" or "FileChannel with a wrapped array ByteBuffer and direct array access" are the way to go.

    The blog article gives examples, which I sort of understand, but as a newbie to Java I'm not quite clear how I can integrate the update() method.

    Probably a very simple answer, but I'm suffering a bit of code-writer's block, so perhaps someone would be kind enough to help me understand what I need to do ?

    Thank you in advance !

    P.S. If it is of any significance, I will likely be using the IAIK crypto toolkit. RSAPss javadoc can be found here.
    Last edited by JavaLatte; 05-11-2011 at 03:32 PM.

Similar Threads

  1. Large Wave Files
    By dane1193 in forum New To Java
    Replies: 2
    Last Post: 02-18-2011, 11:59 PM
  2. Copying large files efficiently
    By bayan in forum New To Java
    Replies: 2
    Last Post: 10-27-2010, 06:01 PM
  3. Reading large XML
    By gkumar in forum XML
    Replies: 3
    Last Post: 08-06-2009, 05:38 AM
  4. Compare 2 large files
    By bezudar in forum Advanced Java
    Replies: 3
    Last Post: 11-23-2008, 03:18 AM
  5. OutofMemory while downloading large files through FTP
    By deb_santanu in forum Advanced Java
    Replies: 0
    Last Post: 11-13-2008, 02:04 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts