loss of data depending on security permissions

  • Thread starter Christian Schott
  • Start date
C

Christian Schott

Hallo Java Programmer People.

Hopefully that is the right Place for asking that Question, otherwise
i apologize for wasting your time.

I load a Bitmap (filename.bmp) in an Applet from a the Webserver that
hosts the Applet.

BufferedImage bi = ImageIO.read(url);

Unfortunately some Data seems to be lost on its way.
If I Read *.bmp Images it seems that some Rows of the Bitmap are not
fully loaded, they are partly set to Black.
If I Read JPEG Images instead the dataloss has the effect that the
images are a little wishy-washy.

In the Netbeans IDE everything works fine if i use Debug mode.
The same if i grant all permissions in the java.policy file.

Any suggestions where the problem comes from and maybe how to get rid
of it without granting permissions.

Any Help on this would be great !

Thanx for spending your time in reading this.

regards

Christian Schott

Plattform: Windows
Browser : Netscape and IE using the latest Java Plugin.
 
C

Christian Schott

Hallo Andre




just to make clear that it is an *.bmp file.
What are you gonna call your
other picture? [ ;-) ]

Actually the Images are streamed via ASP and not named at all ;-).
What applet? What web server? What URL?

A Java2 Applet written using the sun sdk j2sdk1.4.1_04.

I HAVE TO use IIS as Webserver.

regardz

Christian Schott
 
J

John Davison

Christian Schott said:
Hallo Java Programmer People.

Hopefully that is the right Place for asking that Question, otherwise
i apologize for wasting your time.

I load a Bitmap (filename.bmp) in an Applet from a the Webserver that
hosts the Applet.

BufferedImage bi = ImageIO.read(url);

Unfortunately some Data seems to be lost on its way.
If I Read *.bmp Images it seems that some Rows of the Bitmap are not
fully loaded, they are partly set to Black.
If I Read JPEG Images instead the dataloss has the effect that the
images are a little wishy-washy.

In the Netbeans IDE everything works fine if i use Debug mode.
The same if i grant all permissions in the java.policy file.

You don't need extra security permissions to load a URL from the server
hosting the applet.

Are you sure that "data is lost of the way"? Can you verify that? Could it
be the way you're displaying the Image? Or could it be your ASP script
sending the image? Perhaps it's not sending the correct header information,
such as the size and dimensions of the image.

Suggestions:
Use a sniffer to verify URL transactions: compare these transactions to one
made by a web browser and see if there is any difference.
Save the downloaded image to a file and do a binary compare. Download the
image through a web browser and compare it to your original.
 

Members online

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top