Package org.openqa.jetty.http

Examples of org.openqa.jetty.http.HashUserRealm


        constraint.addRole("user");
        constraint.setAuthenticate(true);

        context.addSecurityConstraint("/tests/html/basicAuth/*", constraint);
        HashUserRealm realm = new HashUserRealm("MyRealm");
        realm.put("alice", "foo");
        realm.addUserToRole("alice", "user");
        context.setRealm(realm);

        SecurityHandler sh = new SecurityHandler();
        context.addHandler(sh);
    }
View Full Code Here

TOP

Related Classes of org.openqa.jetty.http.HashUserRealm

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.