The May 17, 2012 solar event: back-tracing analysis and flux reconstruction with PAMELA