Hey Srikanth,
The reason why you are getting redirected is because you are getting hit by the default security configuration. I would suggest to you to provide configuration (that would kick in before the flowable-task one) and you would configure the authentication for it in there. You can find the flowable-task SecurityConfiguration
here
Cheers,
Filip