Files
TS_WIFILED/docs/client_html/ar01s26.html
2020-04-04 17:21:07 +02:00

4 lines
4.3 KiB
HTML
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>Custom passwords</title><link rel="stylesheet" href="ts3doc.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets V1.74.0"><link rel="home" href="index.html" title="TeamSpeak 3 Client SDK Developer Manual"><link rel="up" href="index.html" title="TeamSpeak 3 Client SDK Developer Manual"><link rel="prev" href="ar01s25.html" title="Custom encryption"><link rel="next" href="ar01s27.html" title="Other events"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><img id="logo" src="images/logo.png"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Custom passwords</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="ar01s25.html"><img src="images/prev.png" alt="Prev"></a> </td><th width="60%" align="center"> </th><td width="20%" align="right"> <a accesskey="n" href="ar01s27.html"><img src="images/next.png" alt="Next"></a></td></tr></table><hr></div><div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="password"></a>Custom passwords</h2></div></div></div><p>The TeamSpeak SDK has the optional ability to do custom password handling. This makes it possible to allow people on the server (or channels) with passwords that are checked against outside datasources, like LDAP or other databases.</p><p>
To implement custom password, both server and client need to add custom callbacks, which will be spontaneously called whenever a password check is done in TeamSpeak. The SDK developer can implement own checks to validate the password instead of using the TeamSpeak built-in mechanism.</p><div class="literallayout"><p><br>
</p></div><p>Both Server and Client Lib can implement the following callback to encrypt a user password. This function is called in the Client Lib when a channel password is set.</p><p>This can be used to hash the password in the same way it is hashed in the outside data store. Or just copy the password to send the clear text to the server.</p><div class="funcsynopsis"><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">void <b class="fsfunc">onClientPasswordEncrypt</b>(</code></td><td><var class="pdparam">serverID</var>, </td><td> </td></tr><tr><td> </td><td><var class="pdparam">plaintext</var>, </td><td> </td></tr><tr><td> </td><td><var class="pdparam">encryptedText</var>, </td><td> </td></tr><tr><td> </td><td><var class="pdparam">encryptedTextByteSize</var><code>)</code>;</td><td> </td></tr></table><div class="paramdef-list"><code>uint64 <var class="pdparam">serverID</var></code>;<br><code>const char* <var class="pdparam">plaintext</var></code>;<br><code>char* <var class="pdparam">encryptedText</var></code>;<br><code>int <var class="pdparam">encryptedTextByteSize</var></code>;</div><div class="funcprototype-spacer"> </div></div><a class="indexterm" name="idm44835433129584"></a><div class="itemizedlist"><ul type="disc"><li><p><em class="parameter"><code>serverID</code></em></p><p>ID of the server the password call occured</p></li><li><p><em class="parameter"><code>plaintext</code></em></p><p>The plaintext password</p></li><li><p><em class="parameter"><code>encryptedText</code></em></p><p>Fill with your custom encrypted password. Must be a 0-terminated string with a size not larger than <em class="parameter"><code>encryptedTextByteSize</code></em>.</p></li><li><p><em class="parameter"><code>encryptedTextByteSize</code></em></p><p>Size of the buffer pointed to by <em class="parameter"><code>encryptedText</code></em>.</p></li></ul></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="ar01s25.html"><img src="images/prev.png" alt="Prev"></a> </td><td width="20%" align="center"> </td><td width="40%" align="right"> <a accesskey="n" href="ar01s27.html"><img src="images/next.png" alt="Next"></a></td></tr><tr><td width="40%" align="left" valign="top">Custom encryption </td><td width="20%" align="center"><a accesskey="h" href="index.html"><img src="images/home.png" alt="Home"></a></td><td width="40%" align="right" valign="top"> Other events</td></tr></table></div></body></html>