mirror of
https://gitlab.com/Mr_Goldberg/goldberg_emulator.git
synced 2024-11-23 20:38:07 +01:00
GetEncryptedAppTicket can be called with cbMaxTicket=0 to get the ticket size.
This commit is contained in:
parent
48ea1da91f
commit
a36d6e475d
1 changed files with 8 additions and 1 deletions
|
@ -374,8 +374,15 @@ SteamAPICall_t RequestEncryptedAppTicket( void *pDataToInclude, int cbDataToIncl
|
||||||
bool GetEncryptedAppTicket( void *pTicket, int cbMaxTicket, uint32 *pcbTicket )
|
bool GetEncryptedAppTicket( void *pTicket, int cbMaxTicket, uint32 *pcbTicket )
|
||||||
{
|
{
|
||||||
PRINT_DEBUG("Steam_User::GetEncryptedAppTicket %i\n", cbMaxTicket);
|
PRINT_DEBUG("Steam_User::GetEncryptedAppTicket %i\n", cbMaxTicket);
|
||||||
if (!pcbTicket || !pTicket) return false;
|
if (!pcbTicket) return false;
|
||||||
unsigned int ticket_size = encrypted_app_ticket.size() + 126;
|
unsigned int ticket_size = encrypted_app_ticket.size() + 126;
|
||||||
|
if (!cbMaxTicket) {
|
||||||
|
*pcbTicket = ticket_size;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!pTicket) return false;
|
||||||
|
|
||||||
//TODO figure out exact sizes?
|
//TODO figure out exact sizes?
|
||||||
if (ticket_size < cbMaxTicket) cbMaxTicket = ticket_size;
|
if (ticket_size < cbMaxTicket) cbMaxTicket = ticket_size;
|
||||||
char ticket_base[] = {0x08, 0x01};
|
char ticket_base[] = {0x08, 0x01};
|
||||||
|
|
Loading…
Reference in a new issue