factorize + add debug logs for fragment/key loading
catch frag/key loading security errors

will help investigating issue such as https://github.com/mangui/HLSprovider/issues/72