Thanks for your query.Based on the facts that you have posted it appears that you have painful bump between anus and Testicles.
This could be due to either Perineal abscess
or Periurethral Abscess
. However the final diagnosis can be confirmed only on clinical examination by a qualified General Surgeon.
Please consult General Surgeon
for clinical evaluation.He may prescribe you antibiotics and/or minor surgery of Incision and drainage
of a abscess.