text stringlengths 0 1.36k |
|---|
**Alex Sexton:** \[11:59\] Yeah, interesting choice. |
**Rachel White:** Somebody that doesn't know anything about this kind of stuff, a.k.a. me, or someone else that doesn't necessarily have to deal with the security side of the code that they write, what would be the best resource for somebody that wants to know how to actually authenticate stuff in a secure way that wou... |
**Alex Sexton:** I don't know if I'm answering your question directly, but if you're building a website and you wanna make sure your website is secure, Mozilla Observatory is a really good option. It will scan your website, it will check your TLS certs (some of this is involved there) and then it will check content sec... |
**Rachel White:** Cool, that's awesome. I didn't even know about that site, so that is helpful. |
**Mikeal Rogers:** I think also maybe we can call out a couple good application layer authentication schemes, as well. One of the problems with updating and getting rid of this is that people take their best practices from their common tools, and not using a secure hashing is not sending a very good message. Alex, you ... |
**Alex Sexton:** This seems like a broad question. How do we auth our employees? |
**Mikeal Rogers:** How do you auth customers? Do you actually encrypt or hash different pieces of the Stripe thing -- I hope you do... I hope that my credit card number is not just sitting there... \[laughs\] |
**Alex Sexton:** Yeah, so PCI determines all of the algorithms for how you must store credit card numbers and things like that. I have a pretty good guess on what it is, but I'm not even credentialed enough to touch or look at any of that code as an early employee at Stripe. That's another one of the security precautio... |
This one's bad - I don't think too many people are using SHA1. Even if you use HMAC or SHA1 it's fine. There's even ways to make SHA1 fine, but use bcrypt to do passwords... Actually, my number one recommendation is don't implement any security stuff yourself. Use libraries that are well known and well tested. The numb... |
**Mikeal Rogers:** Agreed. I tend to rely on modules written by smarter people than me. |
**Alex Sexton:** Right. The wide use of something signals far more security than a smart person, too. Someone can be smart and have a glaring hole that they singularly forgot because there's only one set of eyes on it. You can be pretty sure that the Rails auth stuff works pretty well, because every Saturday night it w... |
**Mikeal Rogers:** \[16:00\] Unless Linus Torvalds is maintaining that library, then... |
**Alex Sexton:** Sure, sure, sure. \[laughter\] But at least it's well known. No one's being quiet about it. |
**Mikeal Rogers:** Yeah. I've actually been using Sodium encryption an signing. I don't know who came up with the standard, but Mathias Buus in the Node community has gotten really into it. There's really good libraries that work both in the browser and in Node, and it's a really good, consistent, easy way to do signin... |
**Rachel White:** The stuff that I've seen from previous jobs that I was at where we did a lot of Node stuff was more built into CI tests, so when it would check to make sure all the tests pass, it would also check for known vulnerabilities and maybe certain npm packages, or the way that code was written. Would that be... |
**Mikeal Rogers:** It's a good practice to -- Snyk has a service that you can plug your open source module into (I believe for free), on your GitHub PRs and stuff like that. It will check if you have any vulnerabilities, and there's obviously a proprietary version as well. That looks through your npm tree and sees if t... |
But that's really just for known vulnerabilities, things we've already seen out in the wild. It doesn't really protect you against bad practices. Also, you run into this problem... Like Alex was saying, if nobody is using the module, then nobody is probably going to take the time to find these vulnerabilities early on.... |
I think we're pretty good there. I think that we're actually coming into the time for a break now. |
**Break:** \[18:04\] to \[\\00:18:51.08\] |
**Mikeal Rogers:** Alright, let's dive into this a little bit. A relatively routine new version of Node came out - 7.6. We do these releases all the time, but this one is a big deal, and people are making a big deal out of it because V8 got updated in the background. They've been doing a lot of work so that we can actu... |
I'm curious what you all think of this and what your views are on it? Before I get into my views... |
**Alex Sexton:** I don't have a ton of opinions... I understand the two sides of this, and I feel like... I mean, I think the primary -- at least the thing people are calling their primary concern is performance of this, versus callbacks or Promises or whatever. I think that's silly, because a) it will get faster the n... |
\[20:08\] It's primarily sugar; I guess there are the people who dislike sugar and there are people who like sugar. Just use whatever you want, I don't know... I dislike that this is an issue. |
**Mikeal Rogers:** You're just trying to make yourself above the controversy. |
**Alex Sexton:** Yeah, exactly. |
**Rachel White:** Why don't you explain the controversy for us, Mikeal? |
**Mikeal Rogers:** Look, there's a long, long argument against Promises. There's just a lot of people that don't like Promises. I actually don't care about Promises, I'm fully in the "do whatever you want, I don't care" camp... |
**Rachel White:** I'm telling your wife. |
**Mikeal Rogers:** ...but it does get annoying that people act like this is revolutionary. A lot of the articles that were written about this feature coming into Node are like, "Node finally tackles asynchronous programming." Node 0.0.2 tackled asynchronous programming. Asynchronous programming has been part of Node si... |
And callbacks... The standard callback interfaces has kind of wrangled that into something usable and really fast. I think Promises landed a while ago in V8; people have been using Promises though since early Promise standards. Bluebird is based on the Promise standard, which is the really fast one, that people really ... |
**Alex Sexton:** I feel like people used Promises far before it was even STDIN V8, or whatever. |
**Mikeal Rogers:** Right. And before it was a standard, there were all these competing standard for Promises. If you go back far enough, you just could not get two people to agree on the same Promise. |
**Alex Sexton:** Well, you couldn't get jQuery to agree with the rest... KrisZyp and Promises A/A+ that was pretty early on, I feel like... Maybe not. |
**Mikeal Rogers:** So what Alex is hinting too is this fight in CommonJS over which standard would be the Promise standard. He said A/A+ because there was also Promises/B, C and I believe D, and I don't know how many letters we got up to. |
**Alex Sexton:** No one used those, though. They were just proposals. |
**Mikeal Rogers:** Right. But anyway, I think that Domenic Denicola did a ton of work just to get Promise people to agree on the same spec, or at least get everybody to stop listening to the people who were detracting. It got like a real STDIN the language, which a lot of people that don't like Promises don't like. I p... |
So it's nice to have a standard that going forward - if you look at the Fetch API and some of these new browser APIs - you have something unified, which is so good. |
**Alex Sexton:** To be clear, Promises made it into the DOM specification, not ECMA, right? |
**Mikeal Rogers:** Well, it's sort of in both. Async/await is a feature in the JS language, and it effectively yields a Promise, and it relies on that standard. You're getting into this annoying territory where we have two standards bodies working on the web platform. |
**Alex Sexton:** Yeah, but the Promise object doesn't have to exist in Node (the native Promise), and it just kind of does because V8 does. |
**Mikeal Rogers:** \[24:05\] Right, but there's some really low-level hooks. Now we're gonna get into some NodeJS details. There's a lot of tracing and debugging that you can do in NodeJS, especially in production systems to really get at the underlying state that's going on. There's all kinds of different methods to g... |
But Promises don't have that kind of hook yet - native Promises don't have the hook yet in V8, so there's work that needs to be done to get an equivalent thing happening at the native level, which at that point actually will make it much more valuable to use native Promises, rather than something like Bluebird. But any... |
**Alex Sexton:** Yeah. It doesn't tackle a lot of the core problems people have with Promises, namely error eating, right? |
**Mikeal Rogers:** Yeah. |
**Alex Sexton:** But I think if you're already using Promises, async/await can be a nice update to your code style. I think for the most part it's fine - you don't have to use it, no one's forcing anyone to use it. You can almost always write a little wrapper around some dependent library that uses it to switch it back... |
**Mikeal Rogers:** Nobody uses fibers... |
**Alex Sexton:** I know, I intentionally said something that no one uses. \[laughter\] But I think it's a silly argument, just because it's sugar -- most of the time, performance on it is not going to matter materially at all, and you can choose to not use it, so... Deal with it. |
**Mikeal Rogers:** Yeah, that's a really good recap. \[laughs\] I wanted more controversy. Rachel, come in and tell me how much you love Promises real quick... I'm just kidding! |
**Rachel White:** That's the thing - now that I don't write a ton of production code, I can do whatever I want. Nothing makes me angry, because if it does I'll just do it a different way, so I'm pretty much indifferent about arguments in regards to code preferences. As long as it works, I'm happy with it. |
**Mikeal Rogers:** We're not gonna have very good arguments on this podcast if everybody's above arguing. \[laughter\] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.