The following lines of code are identified by the line number tothe left. The code in this function has a buffer overflowvulnerability. How can this code be corrected?
Increase the size of the character array inp on line2
Change the printf function on line 5 to only print 16 charactersfor tag and inp
Change the gets function on line 4 that takes one argument tothe fgets function that takes three arguments.
Increase the size of the character array tag on line1
The following lines of code are identified by the line number to the left. The code in this function has a buffer overfl
-
- Site Admin
- Posts: 899603
- Joined: Mon Aug 02, 2021 8:13 am