Version 1
[yaffs-website] / web / core / modules / editor / tests / modules / src / EditorXssFilter / Insecure.php
diff --git a/web/core/modules/editor/tests/modules/src/EditorXssFilter/Insecure.php b/web/core/modules/editor/tests/modules/src/EditorXssFilter/Insecure.php
new file mode 100644 (file)
index 0000000..41ba6a4
--- /dev/null
@@ -0,0 +1,21 @@
+<?php
+
+namespace Drupal\editor_test\EditorXssFilter;
+
+use Drupal\filter\FilterFormatInterface;
+use Drupal\editor\EditorXssFilterInterface;
+
+/**
+ * Defines an insecure text editor XSS filter (for testing purposes).
+ */
+class Insecure implements EditorXssFilterInterface {
+
+  /**
+   * {@inheritdoc}
+   */
+  public static function filterXss($html, FilterFormatInterface $format, FilterFormatInterface $original_format = NULL) {
+    // Don't apply any XSS filtering, just return the string we received.
+    return $html;
+  }
+
+}