Allan George Matthews, 56, admitted to "removing tissue" from the man "without consent or authority" at a motel in Port Macquarie, north of Sydney.
Police said 52-year-old victim posted an online ad "requesting assistance with a medical issue".
He had been suffering for years after being kicked in the groin by a horse.
Police became aware of the case in June when the man attended hospital after the the wound he suffered during the operation became infected.
Officers raided Matthews' home and seized medical equipment, firearms and four bottles of what they suspected to be amyl nitrate.
Prosecutors alleged that Matthews was not authorised to perform such a procedure as he was not a qualified or registered medical practitioner.
He also pleaded guilty in court this week to illegally possessing a gun and two counts of possessing or attempting to prescribe a restricted substance.
An amateur surgeon in Australia has pleaded guilty to removing the left testicle of a man who could not afford professional medical treatment.