hi i tried to allocate memory continuously using calloc function . so obviously the system memory gets filled and crashed. But the worst part is even if i am a standard user and if i am able to run that program the system is crashing . how can we block this to happen for standard user.
code used is :
#include <stdio.h>
#include <stdlib.h>
int main()
{
while(1)
{
int *abc;
abc=(int*)calloc(1000,sizeof(int));
}
}
There might be some way to block this , or else user gets ssh access then easily he can crash the system easily .