Rest API Authorization

I am working on rest api of flowable, but there is an issue while I am going to complete the task using api its allow any user to complete the process, for example, I have assigned the processes to the different assignee, but its allow any assignee to complete any process. Please help how to handle this authorization. Can we handle this in from flowable spring security?