XSS Example using erb templates This is a simple example of how to inject a cross-site scripting attack (and also protect against it) in Ruby using erb.