Pierre,
I'd definitely like this in an easy-to-use tool like vcftools or bcftools, but what you've provided seems to work. Thank you for posting this. I will interrogate further later, however...
vcftools --vcf <input vcf file> --snps <variant IDs file> --recode --out <output vcf file>
gives 1695 variants
vcftools --vcf <input vcf file> --positions <variant positions file> --recode --out <output vcf file>
gives 483 variants
vcftools --vcf <input vcf file> --snps <variant IDs file> --positions <variant positions file> --recode --out <output vcf file>
gives 60 variants
java -jar dist/vcffilterjdk.jar --body -f biostar347173.code <input vcf file> > <output vcf file>
gives 2118 variants
1695 + 483 - 60 = 2118 = Yay!!

Please use the format bar to indicate code. I did it for you this time.