# Please help me with secure token

**URL:** <https://community.wowza.com/t/please-help-me-with-secure-token/51214>\
**Category:** Wowza Streaming Engine\
**Tags:** security\
**Created:** [April 26, 2018, 10:56pm UTC](https://community.wowza.com/t/please-help-me-with-secure-token/51214 "2018-04-26T22:56:26Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Andres\_Lopezvictori1](https://avatars.discourse-cdn.com/v4/letter/a/49beb7/32.png) [@Andres\_Lopezvictori1](https://community.wowza.com/u/Andres_Lopezvictori1)\
**Post date:** [April 26, 2018, 10:56pm UTC](https://community.wowza.com/t/please-help-me-with-secure-token/51214/1 "2018-04-26T22:56:26Z")

</div>

hi, the token link expired in some minutes, but in my website the streaming goes offline afthet that time, I think it’s ok that the token link expired, but the streaming should be online anyway right? why the streaming in my main website also get stop ?

This is my example, what im doing wrong?

\<?php $wowzastart = '0'; $wowzaend = strtotime(date('d-m-Y H:i')) + 1200; $secret = 'abcd'; $wowzatoken = 'token'; $hashstr=hash('sha256','stream/mystream?'.$secret.'&'.$wowzatoken.'endtime='.$wowzaend.'&'.$wowzatoken.'starttime='.$wowzastart.'', true); $usableHash= strtr(base64\_encode($hashstr), '+/', '-\_'); echo "http://some.com:1935/stream/mystream/playlist.m3u8?".$wowzatoken."endtime=".$wowzaend."&".$wowzatoken."starttime=".$wowzastart."&".$wowzatoken."hash=".$usableHash.""; ?\>
