V by -ing
Verbs with other meanings
There are two verbs which have the pattern V by -ing/n. Live is followed by by and an '-ing' clause or noun group which indicates a means by which someone gets the money or food that they need to live. The verb profit is followed by by and an '-ing' clause or noun group which indicates the source of profit or benefit for someone.
Many people were forced to live by their wits or to tramp about the country looking for work.
Their aim is to profit by buying replacement shares later at a lower price.