~/talk

Creating Node Addons, C/C++ extensions for fun and profit

Talkat NodeConf 2011 · on Thursday, 2011-05-05· [nodejs]
slides:none on file

Builds a working bcrypt Node addon into a single bcrypt.node module that exposes gen_salt and bcrypt functions, converts JS strings to UTF‑8 char and back to V8 strings, and returns the encrypted result. Uses V8 APIs: local handles, HandleScope and persistent handles, ObjectWrap, and node_set_prototype_method; fixes early segfaults by closing scopes. Claims typical JS→C++ speedups of two orders of magnitude* and shows the init/constructor/export plumbing that makes the module require‑able.

AI-written summary · about

  1. 0:00Intro
  2. 2:09What are Node Addons
  3. 3:40Why would anyone want to do this
  4. 5:08Bcrypt
  5. 6:40Addon
  6. 7:20How does it work
  7. 8:28Basic code
  8. 12:35Handle scopes
  9. 16:12Object wrap
  10. 19:07Ref and signatures
  11. 20:55Bcrypt module
  12. 21:41Bcrypt code
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.