Problem solved thanks to duduf from duik forum.
For anyone interested here is the solution:
– create a one-layer IK on the forearm using a controller on the hand
– create another one-layer IK on the arm, using the same controller
– adjust the “weight” property of the IK of the arm to limit its rotation