Similarity-based privacy protection for publishing k-anonymous trajectories