Painful lump on bone under skin on finger joint?

Ganglion. This sounds like a ganglion cyst also known as a retinacular cyst. This is a fluid filled sac that comes from the tendons that bend down the fingers. To confirm the diagnosis i would recommend trying to remove the fluid with a needle. These usually go away, sometimes they require surgery to remove.
Ganglion cyst. This may be a ganglion cyst or a synovial cyst related to the tendon in the finger or the tendon sheath in the finger. Either way it can be treated with surgical excision. Operation is simple and short.
Tumor. This is probably a glomus tumor but could be one of the other painful tumors. See your dermatologist for treatment and evaluation.