Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove "realm" from hmackey for Long Term credentials #1452

Open
quadriq opened this issue Mar 14, 2024 · 0 comments
Open

remove "realm" from hmackey for Long Term credentials #1452

quadriq opened this issue Mar 14, 2024 · 0 comments

Comments

@quadriq
Copy link

quadriq commented Mar 14, 2024

Hi,

I would like to remove the "realm" value from hmackey for LT-creadentials. Because I would like to have long-term creadentials in a database which are valid for different realms.

here the coed of ns_turn_msg.c, which generates str, which is then used to generate the hmackey

  strncpy((char *)str, (const char *)uname, sz);
  str[ulen] = ':';
  strncpy((char *)str + ulen + 1, (const char *)realm, sz - ulen - 1);
  str[ulen + 1 + rlen] = ':';
  strncpy((char *)str + ulen + 1 + rlen + 1, (const char *)upwd, sz - ulen - 1 - rlen - 1);
  str[strl] = 0;

I can remove the "realm" part from here.. this works. But then I would fail by stun_check_message_integrity_by_key_str method. So ath the end the connection is 401.

however I am not able to understand, how this integrity check involves the realm part.. Can someone give me a hint how to rewrite the integrity check if I would remove "realm" from the key-generation?

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant