applets

Discussion in 'Java' started by superbobm@hotmail.com, Jun 22, 2006.

  1. Guest

    I am writing a signed applet that needs to write to file and use socket
    connections. I have found that even with a signed applet it seems that
    the only way to do this is to edit the .java.policy file and add the
    lines

    permission java.io.FilePermission "*", "write";
    permission java.net.SocketPermission "*", "resolve";
    permission java.net.SocketPermission "*", "connect";

    But I don't want the user to have to do this. I want it done
    automatically. But since I dont have write access to files I can't open
    the policy file myself to do this, so how can I get these permissions?

    I realise there are security implications in doing this, but since it
    is a signed applet the user has to agree to the security certificate.

    Thanks
     
    , Jun 22, 2006
    #1
    1. Advertising

  2. Andrew T. Guest

    wrote:
    > I am writing a signed applet that needs to write to file and use socket
    > connections. I have found that even with a signed applet it seems that
    > the only way to do this is to edit the .java.policy file and add the
    > lines


    Whoa up. I think you are making a mistake right there.

    To get around browser class caching problems*, try launching
    the applet using JWS. ..it is just an experiment, but you are
    very close to it, given the classes are jar'd and signed.

    * I guess you're already using a number of browsers to test.

    Andrew T.
     
    Andrew T., Jun 22, 2006
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Eitan

    Dotnet versus Java-Applets

    Eitan, Nov 8, 2004, in forum: ASP .Net
    Replies:
    40
    Views:
    4,453
    =?Utf-8?B?RXh0cmVtZSBEYXRhc2V0cw==?=
    Aug 6, 2005
  2. shreesh

    Equivalent to JAVA Applets

    shreesh, Oct 18, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    394
    Juan Wajnerman
    Oct 18, 2003
  3. Alan Seunarayan

    Applets (.NET style!)

    Alan Seunarayan, Apr 18, 2004, in forum: ASP .Net
    Replies:
    3
    Views:
    387
    [MSFT]
    Apr 20, 2004
  4. =?Utf-8?B?RXJpYyBEYW4=?=

    Equivalent of applets or ActiveX controls in .NET?

    =?Utf-8?B?RXJpYyBEYW4=?=, Jan 20, 2005, in forum: ASP .Net
    Replies:
    11
    Views:
    2,309
    Ken Cox [Microsoft MVP]
    Jan 20, 2005
  5. Praveen M V

    Downloading files with applets

    Praveen M V, Aug 13, 2003, in forum: Java
    Replies:
    1
    Views:
    346
    Dave Miller
    Aug 13, 2003
Loading...

Share This Page