Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hide Mp3 URL #240

Open
zensabbah opened this issue Feb 22, 2019 · 4 comments
Open

Hide Mp3 URL #240

zensabbah opened this issue Feb 22, 2019 · 4 comments

Comments

@zensabbah
Copy link

Hi, I'm using soundmanager2 in my Drupal website.
I'd like to hide the full path of my mp3, so I'd like to rename the path in the js before loading the stream.
I tried modifying inlineplayer.js and page-player.js but without success.
I tried to rename o.href and soundUrl but the player doesn't start any stream and the webpage (the mp3 link wrong) is loaded.

Any help?

Thanks in advance

Cristian

@scottschiller
Copy link
Owner

@zensabbah Long story short, you cannot hide MP3 URLs, and efforts to do so will not be a good use of your time.

A few examples -

You could try to protect the assets from "hot linking" from other sites, based on the HTTP(s) referrer - but that can be spoofed. You could try preventing right-click -> save as, but people could record the audio playing through the line-out or digitally capture it.

Ultimately, HTML5 Audio() has to get the data from somewhere, and that will be visible in the network panel of the browser's dev tools. From there, it can be opened and saved to disk.

@zensabbah
Copy link
Author

Good Morning! Yes, you'right, I need a solution only for "normal users" without IT knowledge :)
Any ideas?

@liquidotacon
Copy link

Hello, yes I agree with the OP.
Everyone knows its always possible to access the files, but not everyone in the world are nerds like us, and most average people would "give up" if they hovered their mouse over a playlist item and saw in their browser status, "/StringOfConfusingWebDevJargon/", rather than "/the/actual/path.mp3" which the average computer user understands the syntax of.

I'm not too experienced with, but am willing to implement, php redirects or other methods to mask the urls somehow, with someone's help. There must be an "easy" front end or back end layer of protection... I hope!

@zensabbah
Copy link
Author

I was able to take the URL of the file adding the full url during the SoundManager script process and the song was played. But there are more pieces in the code to modify (for pause, playing another song stopping the last played, for changing the icon ecc.)
Should be nice to have documentation of all the script process to easily made modification in the code :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants