Skip to content

cyraxx/amsplugins

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Access plugins for Adobe Media Server

What's all this?

These are two access plugins for Adobe Media Server that prevent unauthorized clients from publishing to your server. They are currently for the 64-bit Linux edition of AMS only.

But doesn't Adobe already supply an authentication plugin for this very purpose?

Yes they do, but it has two major flaws:

  1. It's very easily circumvented. It only checks those clients that connect with an FMLE user-agent string. Any client that supplies a different user-agent string (which, for example, Wirecast does by default) is simply let through without any authentication whatsoever.
  2. It only supports clients that implement Adobe's challenge-response authentication protocol, which many standard RTMP clients don't.
How do your plugins fix this?

There are actually two separate plugins for two separate use cases:

  • The chain plugin. It chain-loads Adobe's original access plugin and passes off any connection from FMLE to that plugin so that the usual user/password authentication system can be used. However, it also fixes the big security problem that Adobe's plugin has by revoking write access for all non-FMLE clients so they won't be able to publish. Use this plugin if you only use encoders supporting Adobe's FMLE authentication system (such as FMLE and Wirecast).

  • The key plugin. It requires all publishing clients to supply a valid key as part of the RTMP URL they're connecting to. This is a little less secure than the chain plugin because the key will be transmitted in plain text but gives you more flexibility because it works with any regular RTMP client.

Couldn't the same thing be done with server-side ActionScript or by using an auth plugin instead of an access plugin?

Yes, but not if you're running the (less expensive) AMS Standard Edition which doesn't support either of those. Basically, the only way to run custom code in AMS Standard is with access plugins like these.

Do these plugins also work with the livepkgr application?

Yes. In the examples below I've only listed RTMP URLs using the live application but these plugins will work for any AMS application.

How to use the chain plugin

  1. Install and configure Adobe's FMLE authentication add-in normally. Check that password authentication works with FMLE.
  2. Make sure g++ and make are installed.
  3. Change into your AMS access plugin directory (usually /opt/adobe/ams/modules/access) and rename libconnect.so to libconnect_chain.so.
  4. Change into the chain source directory and run make. It should compile without errors.
  5. If your AMS is not installed in /opt/adobe/ams, adjust the InstallDir line in Makefile.
  6. As superuser, run make install.
  7. Restart AMS. You should see a line like Auth adaptor chain loaded from ... in syslog and no error messages after that.
  8. You're done. Check that you can still publish with FMLE but can't with, for example, Wirecast.

Note: If you're using Wirecast with the chain plugin you need to set its user-agent to FMLE in the streaming settings.

How to use the key plugin

  1. Create a file called keys in your AMS configuration directory (usually /opt/adobe/ams/conf) and enter some access keys of your choice, one per line.
  2. Make sure g++ and make are installed.
  3. Change into the key source directory and run make. It should compile without errors.
  4. If your AMS is not installed in /opt/adobe/ams, adjust the InstallDir line in Makefile.
  5. As superuser, run make install.
  6. Restart AMS. You should see the line Initializing key access adaptor in syslog.
  7. You're done. Check that you can still publish when supplying a valid key (see below) but can't when not supplying a key.

To publish, you now need to append ?key= and one of the keys from your keys file to your RTMP URL (not the stream name!), for example: rtmp:https://yourserver/live?key=...

If your encoder takes the RTMP URL and the stream name as one combined string it will need to look like this: rtmp:https://yourserver/live?key=.../livestream

About

Two access plugins for Adobe Media Server

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published