ObjectSerialization.php 452 B

123456789101112131415161718192021222324
  1. <?php
  2. namespace Drupal\Core\Test;
  3. /**
  4. * Object to test that security issues around serialization.
  5. */
  6. class ObjectSerialization {
  7. /**
  8. * ObjectSerialization constructor.
  9. */
  10. public function __construct() {
  11. throw new \Exception('This object should never be constructed');
  12. }
  13. /**
  14. * ObjectSerialization deconstructor.
  15. */
  16. public function __destruct() {
  17. throw new \Exception('This object should never be destructed');
  18. }
  19. }