{"issue":{"milestone":null,"user":{"id":636,"login":"qerub","url":"https://api.github.com/users/qerub","avatar_url":"https://secure.gravatar.com/avatar/a19281bdbc5f08539cdef3d6636f7c4d?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","gravatar_id":"a19281bdbc5f08539cdef3d6636f7c4d"},"created_at":"2011-10-26T13:54:56Z","title":"Segfault","state":"closed","updated_at":"2011-12-16T13:58:24Z","labels":[],"id":2056849,"html_url":"https://github.com/pbhogan/scrypt/issues/2","closed_at":"2011-12-16T13:58:24Z","pull_request":{"patch_url":null,"html_url":null,"diff_url":null},"body":"Hello,\r\n\r\nI get hit by segfaults when I try your library:\r\n\r\n```\r\n/Users/qerub/.rvm/gems/ruby-1.8.7-p334/gems/scrypt-1.0.3/lib/scrypt.rb:79: [BUG] Segmentation fault\r\nruby 1.8.7 (2011-02-18 patchlevel 334) [i686-darwin11.2.0]\r\n\r\nzsh: abort      rackup\r\n```\r\n\r\nHere's the top of the stack:\r\n\r\n```\r\n#0  0x00007fff932d1e03 in memmove$VARIANT$sse42 ()\r\n#1  0x00007fff8f822026 in SHA256_Update ()\r\n#2  0x00000001006606cf in PBKDF2_SHA256 (passwd=0x0, passwdlen=0, salt=<value temporarily unavailable, due to optimizations>, saltlen=<value temporarily unavailable, due to optimizations>, c=1, buf=0x101109ff0 \"\", dkLen=128) at sha256.c:386\r\n#3  0x000000010065daa5 in crypto_scrypt (passwd=0x0, passwdlen=0, salt=0x0, saltlen=0, N=16, r=256, p=1, buf=0x0, buflen=0) at crypto_scrypt-ref.c:258\r\n#4  0x000000010065e4b2 in scryptenc_cpuperf (opps=0x7fff5fbf5010) at scryptenc_cpuperf.c:149\r\n#5  0x000000010065df19 in calibrate (maxmem=<value temporarily unavailable, due to optimizations>, maxmemfrac=<value temporarily unavailable, due to optimizations>, maxtime=0.20000000000000001, n=0x7fff5fbf5070, r=0x7fff5fbf507c, p=0x7fff5fbf5078) at scrypt_calibrate.c:41\r\n#6  0x000000010065e311 in sc_calibrate (self=<value temporarily unavailable, due to optimizations>, maxmem=<value temporarily unavailable, due to optimizations>, maxmemfrac=4321026880, maxtime=4321026640) at scrypt_ext.c:25\r\n#7  0x0000000100028d16 in rb_call0 (klass=4320999920, recv=4320999960, id=38857, oid=38857, argc=3, argv=0x7fff5fbf5380, body=0x1018d3978, flags=<value temporarily unavailable, due to optimizations>) at eval.c:5928\r\n```\r\n\r\nAnd the error as reported by GDB:\r\n\r\n```\r\nProgram received signal EXC_BAD_ACCESS, Could not access memory.\r\nReason: KERN_INVALID_ADDRESS at address: 0x00007ffe8c3a0490\r\n0x00007fff932d1e03 in memmove$VARIANT$sse42 ()\r\n```\r\n\r\nLet me know if you need any more information.\r\n\r\nRegards,\r\nChristoffer","number":2,"url":"https://api.github.com/repos/pbhogan/scrypt/issues/2","comments":2,"assignee":null},"action":"closed"}