Class SkyViewDetainter

java.lang.Object
skyview.request.Detainter
skyview.request.SkyViewDetainter

public class SkyViewDetainter
extends Detainter
This class defines string patterns and rules that are used to do taint checking for Skyview CGI calls. A hash map of acceptable character patterns is created upon construction and are matched against user input associated with each CGI parameter. If the pattern for a CGI parameter is not found the input is checked for characters that are not allowed. Some parameters such as survey name are checked against a pattern of allowed characters and then checked again to make sure certain sequences of allowed characters are not present.
  • Constructor Summary

    Constructors 
    Constructor Description
    SkyViewDetainter()  
  • Method Summary

    Modifier and Type Method Description
    boolean checkInvalid​(java.util.regex.Pattern pattern, java.lang.String name, java.lang.String input)  
    boolean isValid​(java.util.regex.Pattern pattern, java.lang.String name, java.lang.String input)  
    boolean validate​(java.lang.String name, java.lang.String input)  

    Methods inherited from class skyview.request.Detainter

    addPattern, getPattern

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • validate

      public boolean validate​(java.lang.String name, java.lang.String input) throws java.lang.Exception
      Specified by:
      validate in class Detainter
      Throws:
      java.lang.Exception
    • isValid

      public boolean isValid​(java.util.regex.Pattern pattern, java.lang.String name, java.lang.String input) throws java.lang.Exception
      Throws:
      java.lang.Exception
    • checkInvalid

      public boolean checkInvalid​(java.util.regex.Pattern pattern, java.lang.String name, java.lang.String input) throws java.lang.Exception
      Throws:
      java.lang.Exception