As I understand it, following the unification of Japan restrictions were put in place on who was allowed to own and bear weapons and in what manner. Specifically, while sword ownership was legal for commoners, only samurai were permitted to own "longswords" and/or wear more than one sword.
My question is, did these restrictions also apply to the ashigaru? What sort of swords were they permitted to carry? Or did they even really carry swords at that point given that matchlock tanegashima were starting to become widespread?
My reason for asking this is kind of a weird one - I paint miniature military models and someone gave me a set from the Test of Honour miniatures game (which is set in the Sengoku era) and I noticed that all the ashigaru had been modelled with two swords (which, again, I thought was exclusively a samurai thing in and around that timeframe). I'd like the models to be, within reason, somewhat historically accurate and I couldn't find any authoritative information one way or the other in my quick online research, so I'm hoping someone here will know.
When people talk about 足軽 ashigaru, they usually think peasants taken out of their fields, with little to no armor and only a polearm or a single sword or even farm instruments. This is a misconception. Though lower in class, ashigaru were generally treated as full warriors, and by the late Sengoku and Edo their equipment could be quite impressive. Also note that in the late Sengoku and Edo at least, ashigaru was a specific rank. The term for "warriors who were not samurai" was not ashigaru but 雑兵 zōhyo. And while I have not examined the records of every clan, in the Takeda and Hōjō records for the high Sengoku at least ashigaru is also used to denote men under direct control of the daimyō. This includes mounted, landed men, which would normally count as samurai, making it sometimes a bit confusing to figure out whether the passage is talking about low class warriors or warriors under direct control of the daimyō.
With that out of the way, the simple answer to your question is they carried two swords. If you zoom in to the painting of the battle of Ōsaka in 1615, it's quite clear that men drawn in enough details for their arms to be visible are depicted with a longsword, even those without helmets or jingasa and with lighter armor. If anything, it seems they were more likely to be depicted without the shortsword, though I can't really tell if that's just the angle/resolution of the depiction or if they're really supposed to be not wearing one. For the most parts though, the combatants are depicted with two swords. The painting was done on the orders of the Kuroda daimyō who was there himself, and is one of the oldest surviving paintings of Sengoku battles, so must have been at least semi-accurate.
The same could be said about other depictions, whether battle drawings
or military manuals like the zōhyo monogatari, which as its title implies is all about the zōhyo, the depiction's the same. Regardless if the person was using a bow, a gun, a polearm, or just holding the unit banners, people going into combat were generally depicted with two swords.
The sword restrictions are mostly late Sengoku (for civilians) and early Edo (for soldiers). Sengoko Period ashigaru could pretty much wear whatever swords they wanted. Oda Nobunaga began to restrict swords, but not to much effect. Toyotomi Hideyoshi's "sword hunt":
Farmers of all provinces are strictly forbidden to have in their possession any swords, short swords, bows, spears, firearms, or other types of weapons.
confiscated many weapons, but farmers was far from disarmed as a result - enforcement was far from thorough. Commoners (specifically, non-soldier commoners) were still carrying long swords, and even two swords, into the 17th century, and there were no restrictions on what soldiers would carry. Edo Period legislation, mostly around the mid-17th century, is responsible for the main restrictions. In 1648, a law restricted the carrying of long swords by commoners in Edo:
All commoners - even those received government stipends - are most strictly forbidden to go sauntering about Edo wearing the long sword.
Exceptions included commoners with special permission to wear the long sword, and during fires or other extraordinary circumstances. More general restriction, applying outside Edo, came with the Tokugawa Muto Rei, "No Sword Order", of 1668 prohibiting commoners from carrying swords with blades longer than 1.5 feet (unless special permission had been given). Finally, in 1683, the wearing of two swords was restricted to samurai, and retainers of samurai were no longer allowed to carry long swords; this is the earliest general sword regulation applying to ashigaru I know of (not counting specific restrictions in Edo, law courts, etc.).
As u/ParallelPain has already noted, ashigaru are frequently shown in art with two swords:
https://commons.wikimedia.org/wiki/File:Strings_for_night_firing.jpg
https://commons.wikimedia.org/wiki/File:Ashigaru_groom_(1).JPG
After the early Edo Period, non-samurai retainers/attendants of samurai and daimyo shouldn't be shown with long swords or two swords. Sengoku Period, anything goes!
Further reading on sword regulations:
Tamara Enomoto, "Giving Up the Gun? Overcoming Myths about Japanese Sword-Hunting and Firearms Control", History of Global Arms Transfer 6, 45-59 (2018).
John Michael Rogers, The development of the military profession in Tokugawa Japan, PhD thesis, Harvard University, 1998.