You can get medicines for these kind of worms. I personally suggest you organic spray which you can prepare at home only. Take chilly and neem leaf juice, mix with a glass of water and spray it on plants leaves everyday and get good results, it may take time to recovery compared to the chemical medicine.