Tarry oxidation products are side products when nitric acid oxidizes aniline and can occur when you don’t protect aniline properly during nitration. If you do protect aniline you would get no meta side products and almost certainly no tarry oxidation products.
Given the pKas of sulfuric acid (-3) and nitric acid (-1.3) aniline is capably protonated (the pKa of anilinium is about 4.6).
What starts happening in nitrating unprotected aniline is sulfuric acid being the strongest acid here may protonate both nitric acid and aniline and that’s when you can get products you don’t want.
You would then have aniline anilinium sulfuric acid nitric acid AND protonated nitric acid in solution.
So notice how trying to nitrate aniline without protecting it can give a mixture of ortho para AND meta nitration products (the meta comes upon protonating some of the aniline and turning the substituent into a meta director).
However when you protect aniline using a Friedel-Crafts Acylation you generate a new ##HN-(C=O)-R## substituent that remains moderately activating (ortho/para-directing) and it will still help you get your ortho/para mixture with less meta side products.
TARRY OXIDATION
Unprotected aniline in addition when not protonated can still act as a nucleophile and attack the protonated nitric acid starting what seems to be the tarry oxidation pathway.
I’ve never learned the mechanism for tarry oxidation but I would propose the following is likely to occur based on this similar reaction (see Figure 1 in the link):
Where the tarry oxidation product formed is only the first intermediate and I believe it would somehow proceed further to make a polymer based on the linked paper which demonstrates a similar oxidation of aniline using silver nitrate (rather than nitric acid).
For the mechanism I think that since the nitro group is a very good electron withdrawing group the oxygen can pull electron density towards it making the nitro nitrogen more electropositive.
That nitrogen then wants to pull electron density from the anilinium nitrogen making that one more electropositive.
But that electropositive nitrogen now wants to pull electron density from one of the benzene carbons which would skew the electron distribution towards the nitrogen in the anilinium ##C-N## bond giving it more ionic character and weakening the bond.
So I think it’s possible that aniline could try to perform nucleophilic aromatic substitution here. This is really the only part where I would be uncertain.
Assuming that it happens then the predicted tarry oxidation product should form. To be honest I would not say that the tarry oxidation is going to yield THAT much product since aniline has a pKa of about 27 making it easy to protonate most of it…
The pKa of the aminonitro side product (nitramide) has been calculated to be about ##6.60 pm 0.30## with an experimental melting point of about ##148~151^@ C## (https://scifinder.cas.org/) so this compound has probably been isolated before long enough to get a melting point range.
Its predicted density is about ##1.378 pm 0.06## ##g/cm^3## (https://scifinder.cas.org/) which is surprisingly on the order of a liquid given that it’s a solid at room temperature.