JW Player和Amazon S3:私人视频,如何管理公钥和私钥?我应该将这些键放在哪里才能在我的网站内播放视频?
我已经安装了 JWPlayer,并且有一个包含一些视频的 Amazon S3 存储桶。 这些视频是私人的,只允许我网站的访问者观看。
现在,我已经有了这段代码,它可以工作:
<div id='container'>Loading the player ...</div>
<script type='text/javascript'>
jwplayer('container').setup({
flashplayer: '/jwplayer/player.swf',
file: 'http://content.longtailvideo.com/videos/flvplayer.flv',
height: 270,
width: 480
});
</script>
我不知道如何管理亚马逊的视频本身。我的意思是,我有一个公钥和一个私钥,我应该把它们放在哪里?因为如果我只是发布视频链接(https://...),它就不会播放,因为它(自然)是“禁止”的。
我应该做什么有什么想法吗?我查看了 jwplayer 的 API,但没有找到任何东西,而不是 设置向导...
任何帮助将不胜感激! 罗莎蒙达
I´ve got JWPlayer installed and I´ve got an Amazon S3 bucket with some videos.
Those videos are meant to be private, allowing only my site´s visitors to watch them.
Now, I´ve got this code, that´s working:
<div id='container'>Loading the player ...</div>
<script type='text/javascript'>
jwplayer('container').setup({
flashplayer: '/jwplayer/player.swf',
file: 'http://content.longtailvideo.com/videos/flvplayer.flv',
height: 270,
width: 480
});
</script>
What I don´t know how to manage is the Amazon´s video itself. I mean, I have a public and a private key, where should I put them? Because if I just post the video´s links (https://...) it won´t play, because it salys "forbidden" (naturally).
Any ideas on what should I do? I´ve look into jwplayer´s API and didn´t found anything, not at the setup wizard...
Any help will be very much appreciated!
Rosamunda
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我认为您应该提供一个身份验证代理,为用户会话设置一个服务器端 cookie,以便让他观看您的视频,但避免将其嵌入或链接到不同的域。
如果不公开视频,就没有其他方法可以做到这一点。
抱歉,如果来得有点晚(我刚刚看到你的问题)。
I think you should provide a proxy for auth, setting a server side cookie for user's session in order to let him watch your video but avoid embedding it or linking it on different domains.
There's no other way to do it without letting videos to be public.
Sorry if this comes a little late (I just saw your question).