[a / b / c / d / e / f / g / gif / h / hr / k / m / o / p / r / s / t / u / v / vg / vm / vmg / vr / vrpg / vst / w / wg] [i / ic] [r9k / s4s / vip] [cm / hm / lgbt / y] [3 / aco / adv / an / bant / biz / cgl / ck / co / diy / fa / fit / gd / hc / his / int / jp / lit / mlp / mu / n / news / out / po / pol / pw / qst / sci / soc / sp / tg / toy / trv / tv / vp / vt / wsg / wsr / x / xs] [Settings] [Search] [Mobile] [Home]
Board
Settings Mobile Home
/g/ - Technology


Thread archived.
You cannot reply anymore.


[Advertise on 4chan]


File: 1714581166737742.jpg (84 KB, 1080x924)
84 KB
84 KB JPG
previous: https://boards.4chan.org/g/thread/108466244/

#define __NR_capget                125
#define __NR_capset 126

https://man7.org/linux/man-pages/man2/capset.2.html
https://man7.org/linux/man-pages/man7/capabilities.7.html

tl;dr:
manage process capabilities

capabilities! really interesting subject. there are like five million different security/permission/capability management systems on linux, and this is one of them. it's actually one of the more important and widely used ones, too. i will give a brief (and certainly biased) overview of the ones i feel actually matter (to most people)
>CAP_BPF
for bpf, of course
>CAP_DAC_OVERRIDE
to override file ownership
>CAP_KILL
to signal processes!
>CAP_NET_*
need i even say it?
>CAP_SETUID
for suid binaries
>CAP_SYS_ADMIN
so fucking overloaded i won't even begin to describe it
>CAP_SYS_NICE
it's important to be nice ^_^
>CAP_SYS_PTRACE
god i love ptrace,,,,
>CAP_SYS_RESOURCE
override rlimits! open all the things

the thread capability set model (permitted, inheritable, effective, bounding, and ambient) is pretty complicated, but seems comprehensive. it's certainly an interesting approach to the problem. it's just really hard to follow sometimes lol

anyone else have experience with these? they're common enough that i would be pretty surprised if no one here had run into them while building software. what'd you run into, how'd you approach it, and what was the end result? share with the class!

relevant resources:
man man

man syscalls

https://man7.org/linux/man-pages/
https://linux.die.net/man/
https://elixir.bootlin.com/linux/
https://elixir.bootlin.com/musl/
https://elixir.bootlin.com/glibc/
>>
File: 1772412200565110.jpg (448 KB, 1280x1699)
448 KB
448 KB JPG
oh man i fucked up the backlink it's so over for me
>>
>CAPITALISM CAPITALISM CAPITALISM CAPITALISM CAPITALISM CAPITALISM CAPITALISM CAPITALISM CAPITALISM
>look inside
>not capitalism
why are socialists like this
>>
>>108473198
That's right. It's only Capitalism if the market is fully free and there is no State. Capitalism has never been practiced on this world.
>>
File: file.png (190 KB, 1816x1200)
190 KB
190 KB PNG
>>108473239
>real capitalism has never bee-ACK
>>
>>108473245
This is not Capitalism. It is State Capitalism. Despite sharing a similar name they are very different things. Under Capitalism the markets are Free and Liberty is naturally provided to every person. Under State Capitalism there are no free markets, the State controls everything and reserves the right to impose regulations and taxes and other burdens upon the market to control it. In China there is no freedom or liberty so China cannot be Capitalist. It is State Capitalist.
>>
>>108473251
...just like every other "capitalist" country?
>Liberty is naturally provided
irrelevant to economy
>State controls everything and reserves the right to impose regulations and taxes and other burdens upon the market to control it
yes?
>>
>>108473251
>This is not Capitalism. It is State Capitalism
NTA, but that's kind of the point. Even if it's not "real" capitalism, making the market any more free than it was results in a predictably larger, more vibrant economy (an "economic miracle", as it's so often described), whereas the opposite results in economic stagnation.
>>
>>108473854
scandinavian countries have deceptively competitive and healthy markets despite the high taxes
>>
Is this in any way related to AppArmour/SELinux or are those separate things? Because they also limit process capabilities or something.
>>
>>108474920
they're related in that they have similar goals, but that's it
>>
>>108473059
Literally nothing uses these
>>
>>108473059
Throwing this out there for no reason, check your systemd services capabilities flags, you might be surprised what services think they need which capabilities.
>>
>>108477294
it's basically how apps on your phone are also very grabby with permissions
>>
>>108473059
>syscall anon likes cute Chinese women
>syscall anon dabs on wokefags
very nice motherfucker
>>
File: corporate-greed.png (328 KB, 500x471)
328 KB
328 KB PNG
>>108473059
>>
>>108473059
image is 100% true
i hate pathological losers so much



[Advertise on 4chan]

Delete Post: [File Only] Style:
[Disable Mobile View / Use Desktop Site]

[Enable Mobile View / Use Mobile Site]

All trademarks and copyrights on this page are owned by their respective parties. Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.