Menu

policyserver.jar question

Public
lonnys
2012-06-22
2013-06-23
  • lonnys

    lonnys - 2012-06-22

    policyserver.jar relies on graphic interface in Linux system ,Who have the policyserver.jar  and  it  do not rely on graphical interface

     
  • lonnys

    lonnys - 2012-06-22

    hi

    My system does not have a graphical interface,Who can help me thank you.

     
  • Marco Fucci

    Marco Fucci - 2012-06-23

    Hi lonnyluo,

    The security policy server is pretty stupid. Here is the code of one not using the graphical interface:

    import java.io.DataOutputStream;
    import java.io.IOException;
    import java.net.ServerSocket;
    import java.net.Socket;

    public class SecurityServer {
    public static void main(String args) {
    ServerSocket ss = null;
    Socket s = null;

    try {
    ss = new ServerSocket(1234);

    while (true) {
    s = ss.accept();

    DataOutputStream os = new DataOutputStream(s.getOutputStream());

    os.writeBytes("<cross-domain-policy><allow-access-from domain=\"*\" to-ports=\"*\" /></cross-domain-policy>");
    os.flush();

    // socket should not be closed at that point
    }
    } catch (IOException e) {
    e.printStackTrace();
    } finally {
    if (ss!=null) {
    try {
    ss.close();
    } catch (IOException e) {}
    }
    }
    }
    }

     
  • lonnys

    lonnys - 2012-06-23

    2012-06-23 00:25:52 PDT
    Hi mfucci
    Thanks for your answer.  I will test it on Monday. I hope there is no problem . thank you again for your help.

     
  • lonnys

    lonnys - 2012-06-25

    hi mfucci
    I have tested the program that you gave me. but the program still has problems. when I run the program  the server can listen on port 1234,but the client is still can not connection and report :
                   An security error occured (Error #2048).
                   Check your policy-policy server configuration or disable security for this domain.
    There is a strange phenomenon . When client  connection  the security policy server  If  I interrupt the service then the client can connect  at once  however  if you refresh the page then clients cannot connect again.

     
  • xamzab

    xamzab - 2013-06-11

    Hi,

    Can anyone show me how to use the code posted by Marco ? I can't find a way to patch the JAR archive and get it running on CLI.

    Thanks

     
  • Marco Fucci

    Marco Fucci - 2013-06-23

    Hi Xamzab,

    What issue do you have with the code?
    There is no need to patch the jar, just compile and run this java code.
    Flash policy is not really related to flashlight-vnc, so the best support will be found on the link posted by lonnys.

    Marco

     

Log in to post a comment.