Even if you get the binary contents, decoding it is quite the undertaking. You can find the format specs here if you want to try it, though:
http://www.libpng.org/pub/png/spec/1.2/PNG-Structure.html
There are existing implementations in Lua, such as this one, but they don’t cover all scenarios (e.g. that one doesn’t support ancillary chunks) and might not work out depending on your usecase.