Better handling of the sha filtering