# compiling jw player for token security

**URL:** <https://community.wowza.com/t/compiling-jw-player-for-token-security/42801>\
**Category:** Wowza Streaming Engine\
**Created:** [April 27, 2014, 8:45pm UTC](https://community.wowza.com/t/compiling-jw-player-for-token-security/42801 "2014-04-27T20:45:44Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rosa\_Blasco](https://avatars.discourse-cdn.com/v4/letter/r/57b2e6/32.png) [@Rosa\_Blasco](https://community.wowza.com/u/Rosa_Blasco)\
**Post date:** [April 27, 2014, 8:45pm UTC](https://community.wowza.com/t/compiling-jw-player-for-token-security/42801/1 "2014-04-27T20:45:44Z")

</div>

Hello,

I am following this manual [http://www.freemancompression.com/weblog/training/creating-a-secure-token-swf-for-jw-player-5-2.html](http://www.freemancompression.com/weblog/training/creating-a-secure-token-swf-for-jw-player-5-2.html) to compile a jw player so that I can use token security, but once I get to the point of compiling I receive these 2 errors:

C:\trunk\fl5\src\com\longtailvideo\jwplayer\utils\Strings.as, Línea 84 1180: Llamada a un método JSONDecoder posiblemente no definido.

C:\trunk\fl5\src\com\longtailvideo\jwplayer\utils\Strings.as, Línea 2 1172: No se encontró la definición com.adobe.serialization.json:JSONDecoder.

Could you please tell me how to solve them, or if they are essential for jw player to work with token?

Thanks

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [April 29, 2014, 7:09pm UTC](https://community.wowza.com/t/compiling-jw-player-for-token-security/42801/2 "2014-04-29T19:09:06Z")

</div>

I’m not sure how to help with this. Have you asked on the JW Player forum? I think this is going to become increasingly difficult because, as I understand it, the source for premium and enterprise editions is not available, so you can only do it with free version which lacks some features, like HLS to the desktop (tho SecureToken is not used in HLS streaming), and JW Player 5, which you are using, I don’t think is available anymore.

Richard

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [May 2, 2014, 1:26pm UTC](https://community.wowza.com/t/compiling-jw-player-for-token-security/42801/3 "2014-05-02T13:26:42Z")

</div>

Have you asked about this on the JW player forum. I think you need Flash Builder to recompile JW player source.

Richard

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [May 2, 2014, 8:22pm UTC](https://community.wowza.com/t/compiling-jw-player-for-token-security/42801/4 "2014-05-02T20:22:07Z")

</div>

The [source code for JW Player 6](http://developer.longtailvideo.com/trac/browser/trunk/jw6) includes a README.txt file with exact instructions on how to build from source.

Keep in mind that SecureToken only works with RTMP (and variants), and you will want to use [HotLinkDenial](https://www.wowza.com/docs/how-to-combat-hotlinking-your-adobe-flash-swf-file)(or htaccess rules to prevent hotlinking) and [RTMPS](https://www.wowza.com/docs/how-to-get-ssl-certificates-from-the-streamlock-service) (preferred) or [RTMPE](https://www.wowza.com/docs/how-to-get-wowza-rtmpe-addon) protocol to make a complete solution

Note that as far as I know the source code for the premium and enterprise versions of JW player are not available, but the main strength of those versions for streaming purposes is HLS to the desktop, which does not support SecureToken.

Richard

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [May 3, 2014, 2:46pm UTC](https://community.wowza.com/t/compiling-jw-player-for-token-security/42801/5 "2014-05-03T14:46:39Z")

</div>

You use SecureToken to ensure that only your player will work with your content, and you use HotLinkDenial to make sure no one will hotlink the player you have secured, and use RTMPS or RTMPE to encrypt the stream itself. So these are all used together. The readme.txt file in the source code has instructions for compiling, I can’t help more with that.

Richard

---

<div class="post-metadata">

**Author:** ![Doug\_Maupin](https://avatars.discourse-cdn.com/v4/letter/d/51bf81/32.png) [@Doug\_Maupin](https://community.wowza.com/u/Doug_Maupin)\
**Post date:** [June 13, 2014, 2:32pm UTC](https://community.wowza.com/t/compiling-jw-player-for-token-security/42801/6 "2014-06-13T14:32:51Z")

</div>

The problem is though, people can view source, grab the swf, and decompile and easily get the token, I know personally that even with obfuscation people can just grab the token even with rtmpe or rtmps. Plus they can spoof the website, I am sure you guys have heard of rtmpdump by now.

---

<div class="post-metadata">

**Author:** ![Rosa\_Blasco](https://avatars.discourse-cdn.com/v4/letter/r/57b2e6/32.png) [@Rosa\_Blasco](https://community.wowza.com/u/Rosa_Blasco)\
**Post date:** [May 2, 2014, 12:36pm UTC](https://community.wowza.com/t/compiling-jw-player-for-token-security/42801/7 "2014-05-02T12:36:52Z")

</div>

So then what version of jw player can I compile without receiving errors? Or what else can I do?

---

<div class="post-metadata">

**Author:** ![Rosa\_Blasco](https://avatars.discourse-cdn.com/v4/letter/r/57b2e6/32.png) [@Rosa\_Blasco](https://community.wowza.com/u/Rosa_Blasco)\
**Post date:** [May 2, 2014, 1:07pm UTC](https://community.wowza.com/t/compiling-jw-player-for-token-security/42801/8 "2014-05-02T13:07:06Z")

</div>

Or can you simply give me the source code of jw player that can be compiled without having any error

---

<div class="post-metadata">

**Author:** ![Rosa\_Blasco](https://avatars.discourse-cdn.com/v4/letter/r/57b2e6/32.png) [@Rosa\_Blasco](https://community.wowza.com/u/Rosa_Blasco)\
**Post date:** [May 2, 2014, 3:42pm UTC](https://community.wowza.com/t/compiling-jw-player-for-token-security/42801/9 "2014-05-02T15:42:52Z")

</div>

Yes I have already asked them and I am waiting for an answer. Flash builder? It was not only needed the adobe flash professional to compile it?

Don´t you have any tutorial about how to use the token with any player without receiving errors?

I do not know what more to do and I need to secure my rtmp

---

<div class="post-metadata">

**Author:** ![Rosa\_Blasco](https://avatars.discourse-cdn.com/v4/letter/r/57b2e6/32.png) [@Rosa\_Blasco](https://community.wowza.com/u/Rosa_Blasco)\
**Post date:** [May 3, 2014, 2:18pm UTC](https://community.wowza.com/t/compiling-jw-player-for-token-security/42801/10 "2014-05-03T14:18:28Z")

</div>

I am already using hotlinkdenial, but although I am using it there are people that continue taking my channel without doing iframe to my webpage.

but, with the source code for jw player 6 I can use secure token no?

I mean the only thing I want is to protect my channel because somone is still stealing my channel ☹
