Package com.denimgroup.threadfix.framework.engine.full

Examples of com.denimgroup.threadfix.framework.engine.full.EndpointQueryBuilder$DefaultEndpointQuery


public class ThreadFixInterface {

    private ThreadFixInterface(){}

    public static EndpointQuery toEndpointQuery(Finding finding) {
        EndpointQueryBuilder builder = EndpointQueryBuilder.start();

        SurfaceLocation location = finding.getSurfaceLocation();

        if (location != null) {
            if (location.getHttpMethod() != null) {
                builder.setHttpMethod(location.getHttpMethod());
            }

            if (location.getPath() != null) {
                builder.setDynamicPath(location.getPath());
            }

            if (location.getParameter() != null) {
                builder.setParameter(location.getParameter());
            }
        }


        if (finding.getIsStatic()) {
            builder.setInformationSourceType(InformationSourceType.STATIC);
        } else {
            builder.setInformationSourceType(InformationSourceType.DYNAMIC);
        }

        if (finding.getSourceFileLocation() != null) {
            builder.setStaticPath(finding.getSourceFileLocation());
        }

        if (finding.getDataFlowElements() != null && !finding.getDataFlowElements().isEmpty()) {
            builder.setCodePoints(toCodePoints(finding.getDataFlowElements()));
        }

        return builder.generateQuery();
    }
View Full Code Here

TOP

Related Classes of com.denimgroup.threadfix.framework.engine.full.EndpointQueryBuilder$DefaultEndpointQuery

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.