It happens quite a lot that a picture is out of focus.
So far i have not found any software that is able to correct this satisfactory, so please ignore this request if you think this is never going to be a properly function feature.
The best method from what i have seen so far is using an unsharp mask.