News for hackers. Stuff that matters.
Re:Facebook Bug – Delete Any Video by gonyea on Friday June 24, 2016 @03:19PM (#11972626)
This reminds me of my main concern with GraphQL, namely that I could never find a good example showing how you weave security within a request. The examples I saw made me feel uncomfortable. Like, the client requests progressed further than I felt they should.

My typical approach to securing REST APIs is to use guard clauses + white lists. This is very explicit and easy to comprehend.

Re:Facebook Bug – Delete Any Video by brokentone on Friday June 24, 2016 @04:36PM (#11973267)
Well, similar to REST, security is not in the spec, but in the implementation.

Different than REST, comes introspection. You would have to advertise fields and mutations to some people that you wouldn't to others, which is a bit of an odd paradigm with how you might do this at scale, but it's not fundamentally different than REST, just looks / feels different.

I haven't seen many people write on the subject for Graph -- in our implementation on Vogue.com, we don't have need of multiple auths. All the fields we describe are "public" and we don't support mutations at this point.

Re:Facebook Bug – Delete Any Video by akeating on Friday June 24, 2016 @03:56PM (#11972927)
The option to look for, irrespective of language of implementation, is "context". An example of usage may be found in https://github.com/graphql/express-graphql. Basically the context (session or user data) is passed into any resolve function you define, so you may relate operations to permissions using some mechanism you define.

Edit: grammar