G.Legman gives a little information at page 378 of his 'The Horn Book' Jonathan Cape 1970:
Most other such songs surviving, or even now being written, are entirely on political and military personages, as in the humorously scatological song - on the purported use of patriotic ladies' 'chamber-lye' to make gunpowder, and the erotic results resulting therefrom - known during the Civil War as 'John Haroldson', and revised during World War I with the change simply of the satirised general's name to 'Von Hindenburg' (printed in 'Immortalia' 1927, p 101, still entitled 'Chamber-Lye'). The original Civil War version had been printed earlier in a rare contemporary booklet under the title of 'The Lay of John Haroldson', probably in Philadelphia. (Copy New York Public, and others located by the Union Catalogue, Library of Congress).Cheers, Stewie.