Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
pseudorandom name
May 6, 2007

what inputs does the attacker control?

Adbot
ADBOT LOVES YOU

Suspicious Dish
Sep 24, 2011

2020 is the year of linux on the desktop, bro
Fun Shoe
Possibly the UID, GID, and PID of the program, which you can check for in a ruleset. PolicyKit is just an authorization rule checker with the option to prompt the system for a password. Even if you crash it, nothing bad happens.

Baxate
Feb 1, 2011

Suspicious Dish posted:

Yes. How would you recommend we interpret the C language in a safe and secure way to evaluate a complex ruleset?

I don't understand why you would want to

Zombywuf
Mar 29, 2008

Suspicious Dish posted:

Possibly the UID, GID, and PID of the program, which you can check for in a ruleset. PolicyKit is just an authorization rule checker with the option to prompt the system for a password. Even if you crash it, nothing bad happens.

datalog

Suspicious Dish
Sep 24, 2011

2020 is the year of linux on the desktop, bro
Fun Shoe

Ludwig van Halen posted:

I don't understand why you would want to

Because system administrators wanted to have complex action authorization rulesets.

pseudorandom name
May 6, 2007

what uses polkit besides the clock control panel?

pram
Jun 10, 2001
yeah the legions of desktop linux janitors out there

pram
Jun 10, 2001
there must be tens, if not dozens

Baxate
Feb 1, 2011

why bother with other languages in a post-C world?

pram
Jun 10, 2001

Ludwig van Halen posted:

why bother with other languages in a post-Go world?

Subjunctive
Sep 12, 2006

✨sparkle and shine✨


if you store a closure (such as a callback or event handler), it can capture referenced objects for the lifetime of the closure, which is often the lifetime of the program. if there are unmanaged references involved, you can end up with undetected cycles and uncollected garbage much like my posting

Suspicious Dish
Sep 24, 2011

2020 is the year of linux on the desktop, bro
Fun Shoe
Yes, but we explicitly collect and destroy the JS Context after running one script. We're very aware of closures building reference cycles.

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

Suspicious Dish posted:

Yes, but we explicitly collect and destroy the JS Context after running one script. We're very aware of closures building reference cycles.

that's the trap! the JSContext is the thread of execution, it's the object graph that matters. they're often reused out of performance concern, which leads to the problem. I'll stop short of turning this into the PL thread, and try to remember to just take a look at the code at some point.

Suspicious Dish
Sep 24, 2011

2020 is the year of linux on the desktop, bro
Fun Shoe
My understanding was that destroying a JSContext would mark all objects rooted in that context, including the global object, as dead, and run a full mark/sweep GC. Since nothing is keeping the closure alive (all references to it come from the global object, which is now dead), it gets collected.

Subjunctive
Sep 12, 2006

✨sparkle and shine✨

Suspicious Dish posted:

My understanding was that destroying a JSContext would mark all objects rooted in that context, including the global object, as dead, and run a full mark/sweep GC. Since nothing is keeping the closure alive (all references to it come from the global object, which is now dead), it gets collected.

objects are not rooted in a context, the JSContext * parameter is just to find the runtime; see also JS_AddRootRT.

pram
Jun 10, 2001
linux

Notorious b.s.d.
Jan 25, 2003

by Reene

the linux desktop: now inseparable from nodejs

OldAlias
Nov 2, 2013

linux-vomica

OldAlias fucked around with this message at 21:14 on Dec 14, 2014

eschaton
Mar 7, 2007

Don't you just hate when you wind up in a store with people who are in a socioeconomic class that is pretty obviously about two levels lower than your own?

Notorious b.s.d. posted:

the linux desktop: now inseparable from nodejs

hmm, maybe dbus should be reimplemented using node.js as part of systemd

someone should suggest it to Debian and Canonical

Notorious b.s.d.
Jan 25, 2003

by Reene

eschaton posted:

hmm, maybe dbus should be reimplemented using node.js as part of systemd

someone should suggest it to Debian and Canonical

just get drunk with lennart and it will be magically funded by redhat

no "democracy" required

leftist heap
Feb 28, 2013

Fun Shoe
when is the year of ubuntu on the phone?

eschaton
Mar 7, 2007

Don't you just hate when you wind up in a store with people who are in a socioeconomic class that is pretty obviously about two levels lower than your own?
I mean, why not just restructure all IPC around http and JSON? seems like it'd fit the Unix philosophy quite well.

pram
Jun 10, 2001
lol forgot about that. literally pissing money into the void

OldAlias
Nov 2, 2013

rrrrrrrrrrrt posted:

when is the year of ubuntu on the phone?

maybe the year is in china

pram
Jun 10, 2001
ubuntu phone vs firefox phone. which is the more massive misallocation of resources

Notorious b.s.d.
Jan 25, 2003

by Reene

eschaton posted:

I mean, why not just restructure all IPC around http and JSON? seems like it'd fit the Unix philosophy quite well.

docker does http and json over a unix socket

pram
Jun 10, 2001
whats wrong with http over a unix socket

Notorious b.s.d.
Jan 25, 2003

by Reene

pram posted:

whats wrong with http over a unix socket

nothing, i guess

it's just an example of the phenomenon eschaton predicted

pram
Jun 10, 2001
it has less overhead than tcp

MrMoo
Sep 14, 2000

Notorious b.s.d. posted:

the linux desktop: now inseparable from nodejs

re-implement systemd using nodejs!

Sapozhnik
Jan 2, 2005

Nap Ghost
unix ipc is so poo poo that the only useful ipc primitive right now is technically part of the networking subsystem

hoping kdbus, er, kdbusfs, gets merged soon! now instead of being part of the networking system the primary ipc mechanism will be part of the filesystem layer! (i understand why, namespacing and access control and poo poo, not saying it's a bad thing, just a funny outcome of ~*the unix philosophy*~)

i'm actually doing an embedded-ish thing that uses dbus as its middleware atm (the embedded-ish thing is not a car). suits teh needs. also being able to control most linux poo poo via dbus in addition to my processes is a plus.

pram
Jun 10, 2001
lol at using dbus

pram
Jun 10, 2001
whats wrong with named pipes huh

pram
Jun 10, 2001
unix sockets and named pipes should be good enough for anyone

MrMoo
Sep 14, 2000

Mr Dog posted:

unix ipc is so poo poo that the only useful ipc primitive right now is technically part of the networking subsystem

At least there is a usable IPC unlike other platforms ...

eschaton
Mar 7, 2007

Don't you just hate when you wind up in a store with people who are in a socioeconomic class that is pretty obviously about two levels lower than your own?

Mr Dog posted:

unix ipc is so poo poo that the only useful ipc primitive right now is technically part of the networking subsystem

this is one reason Mach rules, actual not-suckful IPC, with reasonable namespacing, on-demand launching, etc.

theadder
Dec 30, 2011


pram posted:

ubuntu phone vs firefox phone. which is the more massive misallocation of resources

im gonna say firefox op

Soricidus
Oct 21, 2010
freedom-hating statist shill

eschaton posted:

I mean, why not just restructure all IPC around http and JSON? seems like it'd fit the Unix philosophy quite well.

worse is better

MrMoo
Sep 14, 2000

Soricidus posted:

worse is better

Gnome already tried that with CORBA and Orbit, you can't really beat that for being worse.

Adbot
ADBOT LOVES YOU

Malcolm XML
Aug 8, 2009

I always knew it would end like this.

pram posted:

unix sockets and named pipes should be good enough for anyone

those are transport layer no

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply