in reply to read the file and assign each line to a hash????
Why not just use Email::Simple like you've already been pointed at? Please don't ask the same question multiple times.