I found that Bootstrap 3.3.7 is vulnerable to Cross-Site Scripting (XSS) via the data-target, data-template, data-content, data-title and data-viewport attributes. How can I inject the XSS into these particular attributes?

closed as off-topic by Conor Mancone, MechMK1, Xander, Benoit Esnard, multithr3at3d Aug 9 at 21:00

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions asking us to break the security of a specific system for you are off-topic unless they demonstrate an understanding of the concepts involved and clearly identify a specific problem." – Conor Mancone, MechMK1, Xander, Benoit Esnard, multithr3at3d
If this question can be reworded to fit the rules in the help center, please edit the question.

  • 4
    I thought you had found out that it was vulnerable. Why are you asking now if it is vulnerable? – MechMK1 Aug 9 at 13:41
  • 1
    Hi and welcome. You are asking for exploit to a known/unknown vulnerability. You should first search Github, blog posts all around the web, and if nothing, you should not ask other people, because people prefer to keep exploits private. XSS has a very good coverage in blog posts from some people. – Croll Aug 9 at 13:46
  • 1
    @Kite I'm not trying to "turn you down", I'm trying to find out what you want to know. Learning how to identify and exploit XSS vulnerabilities is completely fine. In fact, feel free to stop by the DMZ once you have enough rep. The fact of the matter is though that questions, seeking to exploit a particular vulnerability without in-depth understanding of the underlying mechanics, are off-topic. – MechMK1 Aug 9 at 13:50
  • 1
    @Kite If you are interested in learning more on this subject, OWASP has an excellent guide on this. This website also contains references to further articles, which should aid your understanding of how XSS works. – MechMK1 Aug 9 at 13:50
  • 1
    I'm sorry if you feel like you're being shut out Kite. No one is trying to stop you from learning. Stackoverflow just isn't your usual forum, and as a result it's just not a great fit for these kinds of questions. The goal here is to create a repository of questions and answers. It's not intended for the usual back-and-forth that you might get in a more typical forum. As a result, very broad questions are very difficult to answer well. Unfortunately, "X is vulnerable, what do I do?" is about as broad as questions get. If you can edit to include more details, you can get a good answer. – Conor Mancone Aug 9 at 14:04

Suggest you look at some of the issues as they were filed against Bootstrap. Sample exploits are provided, examples:

  • Thank you! If I understood, I should try data-target="<img src=x onerror=alert(0)>. I found the bootstrap file on the website (Inspect -> Sources), but how to change this attribute value? – Kite Aug 9 at 18:37
  • You can make it whatever you want. The vulnerability, which is unlikely in most apps, is when any of the data used on the right hand side of '=' is specified by an attacker and is not filtered by the software. – Swashbuckler Aug 12 at 16:41

Not the answer you're looking for? Browse other questions tagged or ask your own question.