Of course, I don't know 'hardware', as you can tell from my technical description, but I have a sample from another tuning peg gear, and the peg and gear for testing, I get to Home Hardware and they have loose bolts of small dimension. I quickly learn that #6 is too large, #4 is too small and they have no #5's where the thread matches.
But you know what works? Do you remember those little chrome bolts with the hex-wrench heads that used to hold expansion cards in the ibm-pc? Perfect match, only 5mm too long, easily compensated by buying a matching nut and my 53-years owned pawnshop 5-string, my first banjo, is back in action!