Searching with synonyms is integrated in the jcr:contains() function and uses the same syntax like synonym searches with Google. If a search term is prefixed with ~ also synonyms of the search term are considered.