hi..thanks for your query
From what you mention, it might be
folliculitis in the areas mentioned.This is caused by a bacterial infection in the hair follicles.For the treatment :
1)Hot compresses may help drain the affected follicles.
2)Antibiotic creams applied to the skin like
mupirocin .
3) Oral anti inflammatory medicines like Ibuprofen/
Paracetamol may help relieve the pain and reduce the inflammatory process.
4) U might require oral anti biotic therapy to reduce the infection .
To prevent further infection:
-Reduce friction from clothing
-Avoid shaving the area if possible (if shaving is necessary, use a clean new razor blade
-Keep the area clean
-Avoid contaminated clothing and change inner wear twice daily
Hope this helps..take care..