有两个c语言写的简单程序(不是我写的),我刚入门,但是在研究程序是不是可能受到安全威胁,请问这两个程序在做什么,还有是不是可能受到安全威胁啊?
谢谢
int main(int argc,char *argv[],char **envp)
{
	char buf[80];
	buf[0]='\0';
	strcpy(buf,argc[1]);
	printf("\n The output of your command is \n");
	system(buf);
	exit(0);
}-----------------------------------
#include <stdio.h>
#include <string.h>
void f(char *str)
{
	char buffer[20];
	strcpy(buffer,str);
	/*search_by_name returns true if the name you enter matches the one in database*/
	if(search_by_name(buffer))
		print("%s is registered\n");
}
main()
{
	char name[20];
	printf("Please enter your name \n");
	gets(name);
	f(name);
	
}