oldbridge pwn challenge

I’m little stuck at this challenge.
I know how to pass canary check and even get stack position,but don’t know
how to get code position and overcome pie.
There is one unused function which supposed have to help me (some useful gadget)
but don’t know how to use this fact?