You're reading the public-facing archive of the Category Theory Zulip server.
To join the server you need an invite. Anybody can get an invite by contacting Matteo Capucci at name dot surname at gmail dot com.
For all things related to this archive refer to the same person.
oh yeah, mike's \parr failing to render reminds me that i had to resort to putting a unicode ⅋ in one of my messages
is there any way to add cmll to the latex environment here?
oh sheesh i guess probably not https://github.com/zulip/zulip/blob/cfa62700809584003468a982605ef724204a5f21/zerver/lib/tex.py
maybe i'll open an issue on the github...
...AAAAAAAAAAAAAA https://github.com/zulip/zulip/blob/243d8ffc5154ac7d52697706c9c6ff3f19a7cc53/zerver/lib/bugdown/fenced_code.py#L366
what are they DOING :scream:
why is it legal, in 2020, to write web apps used by tons of people, while still believing that html is a string
That's not even the worst offense in that file
There's no emoji for Zalgo, have to resort to Cthulhu instead :octopus:
this is maybe continued off-topic but i kinda want to mention this slightly somewhere:
one of the like invited/featured talks at POPL '20 was about secure programming languages
and half or more of the talk was just talking about what existing languages do and stuff
and half of that was just misinformed or dangerous!
like it described PHP as "having language support for sanitization" and hence that being a secure language feature :scream:
or something along those lines
and it brought up ruby's taint system, despite the fact that afaik nobody ever uses that
/offtopic
actually no one more thing:
never even mentioned templating once
iirc
Let's take this to #off-topic ?
ok can i now move this topic to another stream, or
I thought that was impossible?
:face_palm:
well, better it clutters the ct stream than it clutters the ct stream & the bi heyting algebra topic, i suppose
Yeah
Anyways, have I said that
AHHHHHHHH
All of this vaguely reminds me of the Perl talk
let's actually move this to #off-topic though
i'll open a new topic there
Ok
sarahzrf said:
and half of that was just misinformed or dangerous!
Huh, really? Lemme get my hands on that presentation and get back to you. Being a (practical) security/formal guy in-betweener I have a feeling this presentation will trigger me.
Also, what's up with that zulip code? Why do the devs ignore so many layers of abstraction?
You'd almost think Zulip was a commercial product...
Believe it or not it's the commercial, closed-source software that suffer the most in terms of bad code.
That's essentially what I was alluding to :P
Gotcha my man! You see zulip is a commercial product so it was hard to tell if the sarcasm was directed to "Zulip" or to "commercial products".
Stelios Tsampas said:
Huh, really? Lemme get my hands on that presentation and get back to you. Being a (practical) security/formal guy in-betweener I have a feeling this presentation will trigger me.
can you please not use "trigger" flippantly :\
Wait, Zulip is commercial? I was not aware of that
Lemme google "flippantly" first.
Ben Steffan said:
Wait, Zulip is commercial? I was not aware of that
Yes, they do offer commercial services.
Ah well, I guess it makes sense then
anyway here's the talk https://www.youtube.com/watch?v=dhoP-dyIr54
sarahzrf said:
can you please not use "trigger" flippantly :\
Hahah, sure! I deserved that :D.
Okay, two minutes into the talk and I'm already annoyed, cool
oh? i didnt think there was too much objectionable that early
it's nothing too new at that point but not particularly annoying
...I forgot what I was annoyed about
i guess it does get a bit "cmon, just get to the point" when shes like 10 minutes in and going over stuff that's super boilerplate still
Yeah, that's definitely annoying
the presentation seriously felt to me like
"ok web dev 103 class, time to learn about security"
for a lot of it
\>.>
Ah, I think I was already annoyed about the motivation at the start. Like, the numbers she presented just don't seem that high to me?
i mean, wasnt she talking about holes in pieces of software, not just particular intrusions
5 new exploits per day, over _all_ the software that is registered with that particular exploit database? That doesn't seem so much tbh
actually yeah taht does sound kinda low
Perhaps my sense of scale if off here
btw on that topic https://fishinabarrel.github.io/
s t o p u s i n g C
I guess I'm also a bit sour about the fact that this is essentially a corporate presentation where every slide has an oracle logo on it
lol
welcome to conference land 🤪
???
That's not the norm for any software conference I know about
well ok maybe not on the talks
there were for sure logos on the bags n stuff tho
I mean sure lots of people give talks on behalf of company X, but usually they say it once in the beginning and that's it?
yeah
Ah yeah, I guess that's normal
fair enough, that's a different thing
welcome to PL, your options are:
Love how PHP gets the bonus of "Injection prevention" as a library feature but the other languages don't?
:100:
I'm sure that Java also has that as a library feature but ok
...and all the other languages too probs
not to mention that escaping things is the wrong approach
"sanitization" is the wrong way to think about things
first class support my favourite buzzword!
cmon now first-class support can be a real thing
anyway though the fact that PHP encourages you to just pass query strings and interpolate your parameters in
first class support has no defined meaning in my book
when every time ive ever used sql from another language, the interface has let you pass the parameters as separate arguments and it does the interpolation for you
means that php is more dangerous
because it puts the escaping obligation on you
aaaaaaaaaaa
anyway here's a palate cleanser https://www.youtube.com/watch?v=BDnbxBmwNyQ
...probably incomprehensible if you don't have a background in formal verification but
one of the talks i enjoyed the most that i went to ^_^
Love how the implication is that Java is slow mainly because of the gc
is java even very slow
It's fairly slow, from my perspective
But my perspective is also "compared to C++", so
really though i was under the impression that gc pauses were the primary limiting factor in most applications where java wouldnt be applicable
ewww
stop using c++
I'm not using C++ lol
then why is your perspective compared to it
Because I used it for about 6 years
It's by far the language I know the best, too
im so sorry
/shrug
Well the upside is that it definitely taught me that software development is fucked
haha yes
...c++ is the only popular mainstream language ive deliberately avoided learning
(php probably deserves it even more but i was younger and dumber when i learned php)
Sad actually because you could have a lot of fun with C++
It's probably the most cursed language that exists
/me glances at malbolge
lol malbolge is cute
malbolge is what you get if you really try to be evil
u know what ur right
C++ is what you get when you get a bunch of people together and try to make something good
(and also base it off of C)
nah when i wanna have a lot of fun with a cursed language i just write some ruby
or maybe C
yikes
between ruby and C i think i ahve enough cursedness in my life
i do not need those depths that c++ has
coq gives me enough yaks to shave
actually fuck i wonder how cursed coq is compared to c++
Pretty sure it's like a little child
i mean i doubt it beats it but
Like, C++ is seriously fucked
it's pretty fucking cursed
i just wonder whether it's, idk, to the 50% point
dont worry, i have heard Things about c++
i have a pretty decent sense of how cursed it is, i think
here, look, do you know haskell?
I dabble in Haskell
ok, so you know about typeclasses
coq has "typeclasses"
Yep
the way they work is
OK, I am half-way in the presentation and indeed, it's been very, very simple so far. Two things in mind as to why this kind of content has made it in POPL: 1. Many of the more senior members of the audience should not know about that stuff and 2. Oracle is a silver sponsor.
uh
so ordinarily coq has an implicit arguments mechanism for arguments like types, where if u mark an argument as implicit, instead of actually supplying it when you apply the function, it gets inserted implicitly by figuring out what it would have to be for the term to be well-typed
for example
Definition id (A : Type) (x : A) : A := x. Definition id' {A : Type} (x : A) : A := x.
the curlies indicate an implicit argument
you'd write id nat 3
or id' 3
the latter gets expanded to an application of id'
to both nat
and 3
, which is inferrable because the first arg has to be the type of the 2nd arg
this makes polymorphic functions usable
now:
the way typeclasses work is
if a particular qualified identifier is registered as "being a typeclass", then you can mark arguments whose type is an application of that identifier as being implicit and inferred by the typeclass mechanism
Apart from that, and I really have to try to "pick" the lessons from this presentation so far as it not rich in insights, this is a very good example on the gulf between academic "security" and security in the industry. Having worked in exploit. dev./vuln. research labs I can tell you, cognitive load is a thing. And no, people can't just stop using C and switch to dependently typed languages.
...even with type inference :/.
and the typeclass mechanism's inference? well, it's actually one of coq's proof search systems, repurposed
coq has this proof search system based on having a "hint database" and it can try to prove a goal using the lemmas and other kinds of hint in the database
and they repurposed it to automatically locate terms to fill in arguments
(go on, I'll continue later, I'll try not to interrupt the flow).
as "typeclass instance selection"
it's insane
Is it?
Why?
well, it's sort of insane
it's not insane insofar as it's useful
but it's fucking cursed
like
you get zero of the guarantees that a system like haskell's normally gives you
haskell has all this stuff about coherence, where there's supposed to be at most one instance of a given signature
and superclass constraints being smaller or whatever, so that instance search is decidable
and you can mangle those guarantees with various ghc extensions if you want, but
in coq, none of that is there to begin with
you can have 10 different instances of Ord nat
and which one gets picked depends on priority annotations or what order they were registered
Oh, ok
That's... horrible
and typeclass instances are just proof search hints
so if you fuck up, you can totally make a system of instances which leads to nonterminating proof search
and trying to typecheck your term hangs because filling in the instance never finishes
sarahzrf said:
so if you fuck up, you can totally make a system of instances which leads to nonterminating proof search
Hah! Serves them right!
Ah, I mean, if that's the worst that can happen
The metaprogramming mechanism of C++ is inherentely Turing complete, and type computations not terminating is, like, Monday
oh sure
Okay, not strictly true because most compilers actually limit the depth of type level computations
other cursed things: you have full access to the instances hint database as an ordinary hint database, and coq's proof search tool supports hints of various kinds besides just lemmas for application
so you can just
extend the instance selection mechanism
there's a thing called Hint Extern
which lets you add an arbitrary tactic to apply to the goal if it matches a certain condition
so you can add a Hint Extern
to the instances database
and then when coq tries to search for an instance for a particular class, it'll just, invoke your arbitrary tactic
which can be any, yes, turing complete computation you like
in ltac, the tactic language, which is itself absurdly cursed
bbl
oh god dammit this has been the topic in #category theory not the one in #off-topic :face_palm:
whoops
OK, I finished the presentation and here's my two cents.
It is easy to bash this presentation. How can you present annotations or sanitization libraries as "secure" in front of that audience, people that dabble heavily in dependently typed programming and whatnot, and keep a straight face while doing so. Or show elementary content that's just not what you'd expect in POPL. I don't mean to insult the speaker btw: she is definitely skilled in the field she's in, which is more of the applied type, neither theoretical nor hands-on exploitation.
This presentation is a textbook example of the divide between security industry/research in applied security and security from the TCS/type-theoretic/functional perspective. Functional languages are undoubtedly intrinsically more secure, but the old languages cannot go away. You can't give a crash-course in functional programming and expect people to be productive: functional programming is significantly harder to get into, not least because most beginner PL courses focuse on imperative languages. Also, progress in security is done slowly, causes as few perturbations as possible (otherwise it would seriously hurt productivity), it is heavily guided by the so-called "security arms race" and since there's always pressure for short-term gratification, most solutions are heuristics.
@Stelios Tsampas i have a reply, but im gonna make it in the topic over in #off-topic , so u shd go check there
sarahzrf said:
nah when i wanna have a lot of fun with a cursed language i just write some ruby
what's cursed about ruby? i was a big ruby fan a few years back (but have never really revisited it with a "formal" eye)
# will this print 3 or 4? def foo 3 end foo = 4 p foo
# explain what the following program outputs. def foo(*args) [1, 2, 3, 4, 5] end p(foo[1]) p(foo [1])
first things to quickly occur to me, i could probably keep going at a steady pace for a while
i enjoy ruby, but in the same way that i enjoy, like, junk food
god DAMMIT this is the topic in #category theory again :scream:
is there some way to lock it