 Chromium Code Reviews
 Chromium Code Reviews Issue 
            338193002:
    Refactor XSS Auditor string operations.  (Closed)
    
  
    Issue 
            338193002:
    Refactor XSS Auditor string operations.  (Closed) 
  | DescriptionThis change is a precursor to tackling some more difficult cases where we 
need to apply the string manipulations to strings obtained in a more
general manner.
The function cannonicalize() now becomes a method of XSSAuditor, and 
is the main entry point for performing all such operations. Other methods are
renamed to refer to canconicalized strings.
In order to apply this everywhere, canonicalize() needs to know whether any
truncation is to be applied at all (e.g. we're processing the request URL
or post body and must use it all), so introduce a new enum constant for this
case.  Rename the enum while we're at it to indicate its close relationship
to truncation.
Having done this, several methods can now become functions for truncating strings.
I also removed some indentation from eraseAttributeIfInjected().
Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=176339
   Patch Set 1 #Patch Set 2 : rename. #Patch Set 3 : nameFromAttribute() not needed until next CL lands. #
 Messages
    Total messages: 8 (0 generated)
     | ||||||||||||||||||||||||||||