Optimization-based Reactive Force Control for Robot Grasping Tasks