Package net.continuumsecurity.web

Examples of net.continuumsecurity.web.StepException


    public void findRequestWithPassword() throws UnsupportedEncodingException {
        String passwd = URLEncoder.encode(credentials.getPassword(), "UTF-8");
        String username = URLEncoder.encode(credentials.getUsername(), "UTF-8");
        List<HarEntry> requests = getProxy().findInRequestHistory(credentials.getPassword());
        if (requests == null || requests.size() == 0)
            throw new StepException(
                    "Could not find HTTP request with credentials: "
                            + credentials.getUsername() + " "
                            + credentials.getPassword());
        currentHar = requests.get(0);
    }
View Full Code Here


    public void findResponseWithLoginform() throws UnsupportedEncodingException {
        String regex = "(?i)input[\\s\\w=:'\"]*type\\s*=\\s*['\"]password['\"]";
        List<HarEntry> responses = getProxy().getHistory();
        responses = getProxy().findInResponseHistory(regex);
        if (responses == null || responses.size() == 0)
            throw new StepException(
                    "Could not find HTTP response with password form using regex: "
                            + regex);
        currentHar = responses.get(0);
    }
View Full Code Here

TOP

Related Classes of net.continuumsecurity.web.StepException

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.