It depends, as assigning internal resources may be a viable approach in certain situations; however, if the business is considering performing in-house penetration testing, the following should be considered first:
The penetration testers on staff should be experienced, trained, and familiar with a variety of technologies.
The penetration test team should have a different reporting structure than engineering or implementation teams. Separation between those managing the environment and those testing the environment is crucial. No one, no matter how skilled, can objectively test their own work.
Some regulatory bodies have independence requirements that may require organizational changes or additional layers of oversight before they view the test as truly independent. These considerations should be explored to determine if they apply.
A repository of commercial and open source tools should be obtained and updated regularly. As the costs for these tools can be significant, this should be included as part of the decision to avoid unexpected penetration testing costs.
On-staff experienced project management capabilities are needed, especially in larger organizations where coordinating with various business units is needed prior to the test beginning.
Continued training and ongoing monitoring of newly discovered vulnerabilities and threats is necessary.
Staying current and up-to-date with testing methodologies, planning and deliverable artifacts is also necessary.
Penetration testers should have access to a dedicated test lab for developing and testing exploits prior to their use in a production environment.
If these assets are available to an organization or the cost to obtain and maintain them is lower than leveraging a third party, it may be more cost-effective to perform network penetration testing in house. More often than not, it is far more cost-effective to leverage a third party that is already equipped for network penetration testing.