ulimit

hiyelata 19 views 6 slides Feb 09, 2020
Slide 1
Slide 1 of 6
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6

About This Presentation

Linux/ulimit


Slide Content

ulimit (built-in)

$ ulimit -a <<< etc/security/limits.conf ...display and set resources limits for users.

$ ulimit -a ulimit -n core file size (blocks, -c) 0 data seg size (kbytes, -d) unlimited scheduling priority (-e) 0 file size (blocks, -f) unlimited pending signals (-i) 17887 max locked memory (kbytes, -l) 16384 max memory size (kbytes, -m) unlimited open files (-n) 1024 ----------------> DDos attack pipe size (512 bytes, -p) 8 POSIX message queues (bytes, -q) 819200 real-time priority (-r) 0 stack size (kbytes, -s) 8192 cpu time (seconds, -t) unlimited fork bomb max user processes (-u) 17887 -----------------> Bad code virtual memory (kbytes, -v) unlimited recursive file locks (-x) unlimited

Syntax ulimit [-abcdefHilmnpqrsStTuvx] [ limit ] Key -S Set a soft limit for the given resource. -H Set a hard limit for the given resource. -a All current limits are reported. -l The maximum size that can be locked into memory. -m The maximum resident set size. -n The maximum number of open file descriptors. -p The pipe buffer size. -q The maximum number of bytes in POSIX message queues. -r The maximum real-time scheduling priority. -s The maximum stack size. -t The maximum amount of cpu time in seconds. -T The maximum number of threads. -u The maximum number of processes available to a single user. -v The maximum amount of virtual memory available to the process. -x The maximum number of file locks.

Fork Bomb In computing , a fork bomb (also called rabbit virus or wabbit) is a denial-of-service attack wherein a process continually replicates itself to deplete available system resources, slowing down or crashing the system due to resource starvation .

Fork Bomb examples jAVA PERL RUBY . . . BASH :(){ :|:& };: PYTHON import os while True : os . fork() Brainfuck + [ > + ]
Tags