Ballistic Weave

The ballistic weave is an armor mod that allows adding defensive stats to certain clothing items, including outfits, clothing that can be worn under armor, and a small number of hats.

This crafting ability can be learned from Tinker Tom after performing certain quests for the Railroad faction. Once this skill is learned, one can upgrade any applicable clothing item at an armor workbench.

Obtaining the skill
Progress through the initial Railroad faction quests until P.A.M. offers a series of minor Jackpot missions to secure DIA caches. These only become available after completing Boston After Dark and Mercer Safehouse.

After completing the first or second jackpot mission, Drummer Boy will tell the Sole Survivor that they need to speak to Tinker Tom, who will inform them about the old ballistic fiber technology found in the DIA cache. At this point the Ballistic weave is unlocked at any armor workbench and Tom will sell some armored gear of his own.

Upgradable clothing
The following is a list of all clothing items that can be upgraded, and if the item can either be worn underneath armor pieces or is a hat.

Bugs

 * Clean black suit can be modded, but is currently bugged in-game and preventing player character to upgrade it on armor bench; the only solution for this is to use console commands. Tom may occasionally sell armored clean black suits, and those can be upgraded normally.
 * Aggravating the Railroad or choosing the procrastinate dialog option (left) with PAM or Tinker Tom may cause the characters to become bugged and respectively not give the quest or unlock the ability to mod apparel.
 * Due to the dialog flag setting, it is possible to miss the chance of learning this mod. Drummer Boy will keep telling you Tinker Tom wanted to see you but Tinker Tom won't initiate the corresponding dialogue. Console command will fix this.  . Tried this solution on PC, April 24 2016, and can verify that it worked for me.
 * One may also get this mod without doing P.A.M.'s mission by typing: "" in the console.