Yubico Forum
https://forum.yubico.com/

pam_yubico on 64 bit?
https://forum.yubico.com/viewtopic.php?f=3&t=254
Page 2 of 2

Author:  TrinitronX [ Thu Mar 12, 2009 7:11 am ]
Post subject:  Re: pam_yubico on 64 bit?

Nice, good find!

I can see what you're talking about:

Code:
  token_otp_with_password = (char *) password;
  password_len = strlen (token_otp_with_password);

  /* Getting Token value and SSH password */
  [color=#FF0000]strncpy[/color] ((char *) token_otp,
      token_otp_with_password + (password_len - TOKEN_LEN), TOKEN_LEN);


Might this also cause possible security issues? Not sure if this is really exploitable, but since it's in login code, I'm kinda wary.

Author:  fergus [ Thu Mar 12, 2009 12:32 pm ]
Post subject:  Re: pam_yubico on 64 bit?

I uploaded a patch to the pam_yubico google page that should fix most of the things I was having issues with. It now checks the password to make sure its long enough to contain an OTP before it splits it. It also allows users that don't have a yubikey id associated with them to login. This patch also includes the 64-bit patch above. Feedback is appreciated.

Issue report -> http://code.google.com/p/yubico-pam/issues/detail?id=12
Direct link -> http://yubico-pam.googlecode.com/issues/attachment?aid=5317245680863813985&name=pam_yubico-1.11updates2.patch

Author:  Simon [ Tue Mar 24, 2009 2:41 pm ]
Post subject:  Re: pam_yubico on 64 bit?

cmoates wrote:
Here's a diff which I believe fixes the problem. I've tested it on Ubuntu 8.10 64 bit as well as Ubuntu 8.10 32 bit. Anyone else care to try it out?


Hi! I applied a slightly different patch, see:

http://code.google.com/p/yubico-pam/sou ... ail?r=141#

Please check it. I'll likely do another 1.13 release with this later today.

/Simon

Author:  fergus [ Tue Mar 24, 2009 3:01 pm ]
Post subject:  Re: pam_yubico on 64 bit?

Hmm... You may want to malloc an integer to store the retval before setting with pam_set_data. The current scope of retval will get recollected when that function returns. When the data is retrieved that location is probably is use by something else or it could segfault. We should malloc a dynamic memory location and recollect with a 'cleanup' function.

Page 2 of 2 All times are UTC + 1 hour
Powered by phpBB® Forum Software © phpBB Group
https://www.phpbb.com/