Alternatively, join us on Discord.

+-Recent Topics

Listen to MP3 files but not download them

Started by PT_, April 15, 2017, 05:00:57 pm

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

PT_

Situation: my dad wants to host a paid service, where people can pay for his own music to listen online. However, they should not have the possibility to download them, because the service is paid. I tried several tricks to hide them, or making it really hard to find. I tried htaccess, but if I then block the MP3, <audio> doesn't work anymore, so that doesn't help. Another idea was to copy the MP3 to a temp folder, load it in the <audio> tag, and then immediately remove the folder, but I can't get that working yet + an experienced person can easily remove the JS code to remove the folder. Also, in HTML5, there is an option to download the MP3 IMMEDIATELY. I can remove that with CSS, but again, an experienced user can display it again, and download it.

@c4ooo said I can maybe stream it, so downloading them second by second, which might work, so I might give that a try.

Any more ideas? :)

gameblabla

Maybe base64 the mp3 file, decode it and then use the Web Audio API to play it ?

p2

if he gets the first beta running, I'd love to volunteer as a tester, trying to download the songs ^^
(got a lot of experience on the *regular* methods not involving special toos)
Anyway war sucks. Just bring us your food instead of missiles  :P ~ DJ Omnimaga (11.10.2016 20:21:48)
if you cant get a jframe set up, draw stuff to it, and receive input, i can only imagine how horrible your game code is _._   ~ c4ooo (14.11.2016 22:44:07)
If they pull a Harambe on me tell my family I love them ~ u/Pwntear37d (AssangeWatch /r/)
make Walrii great again ~ DJ Omnimaga (28.11.2016 23:01:31)
God invented the pc, satan the smartphone I guess ~ p4nix (16.02.2017 22:51:49)

Juju

You can use websockets to stream the music, use almost unreadable, minfied code so it will be quite hard to assemble it back together, you might even use encryption as an additional step, but keep in mind, someone will always be able to figure it out, because once you listen to it online, your browser is technically downloading it so you can listen to it.

Anyway, I'd recommend your dad not to reinvent the wheel and use things like Bandcamp, iTunes or Google Play as they do a good job for his use case.
Read Zarmina!
YUKI-CHAAAANNNN
In the beginning there was walrii. In the end there will be walrii. All hail our supreme leader :walrii: --Snektron



if you wanna throw money at me and/or CodeWalrus monthly it's here

_iPhoenix_

Also, you cannot stop me if I play it and record it (using a different device) while it is playing.

If you know someone is doing that to your music, you are a stalker with no life.
Please spam here: https://legend-of-iphoenix.github.io/spam/

"walruses are better than tuxedo chickens, all hail the great :walrii:" ~ me
Evolution of my avatar:

gameblabla

I told @P_T on irc that you could use this example as a base :
https://alexgibson.github.io/offlinewebaudio/

It's basically what i said : Encode the audio as base64 data, decode it and play it back with the Web Audio API.
He told me he was happy about it, even though most people would prefer to use streaming over that of course.
(since they can protect it and encrypt it more easily)

Quote from: _iPhoenix_ on April 15, 2017, 09:43:09 pm
Also, you cannot stop me if I play it and record it (using a different device) while it is playing.

Also known as the (anal)ogue asshole.
That's why Hollywood resorts to DMCA letters these days :D

Juju

Well, yeah. For most of the music industry, the solution isn't always writing better code and safeguards, but sometimes it's more efficient applying copyright law, more specifically, the DMCA. Very liberally. And the biggest ones have good lawyers to back them up.
Read Zarmina!
YUKI-CHAAAANNNN
In the beginning there was walrii. In the end there will be walrii. All hail our supreme leader :walrii: --Snektron



if you wanna throw money at me and/or CodeWalrus monthly it's here

aeTIos

I'd use bandcamp. Simple, easy and contained solution.
ceci n'est pas une signature

DJ Omnimaga

Bandcamp can do the job and is customizeable (layout, subscription options, stream options, etc) but it depends if he wants something customizeable. Bandcamp has an API, though, for webmasters.

gameblabla

Shush guys, his father will give him monez for the work.  :D
Of course most people will stick with Soundcloud or Bandcamp but if @PT_ can get some monez from his father,
you shouldn't say no guys.

p2

if he publishs his stuff on apple music, the files can be downloaded and shared, but they got markings that tell who is the guy gaving bought it from apple (who shared it) which is pretty hard to remove since regular tools wont help u much at this point.
So this already prevents big parts of the picary as noone wants to share a pirated file with his name on it ^^
Anyway war sucks. Just bring us your food instead of missiles  :P ~ DJ Omnimaga (11.10.2016 20:21:48)
if you cant get a jframe set up, draw stuff to it, and receive input, i can only imagine how horrible your game code is _._   ~ c4ooo (14.11.2016 22:44:07)
If they pull a Harambe on me tell my family I love them ~ u/Pwntear37d (AssangeWatch /r/)
make Walrii great again ~ DJ Omnimaga (28.11.2016 23:01:31)
God invented the pc, satan the smartphone I guess ~ p4nix (16.02.2017 22:51:49)

aeTIos

Yeah, but apple music is extremely locked in, I wouldn't use it at all.
ceci n'est pas une signature

DJ Omnimaga

Plus anyone can just convert the file to a different format using any software or recording device anyway. But yeah the main topic here is to make it as hard as possible to download MP3 files while still allowing to stream them.

PT_

Can someone try to get the mp3 from this website WITHOUT recording it? http://www.oefenfiles.nl/ :D (I made something which should prevent downloading it, hopefully ;) )

DJ Omnimaga

I will try on mobile and desktop later. I will also try to run DownThemAll on it to see if I can bypass protections or something.

Powered by EzPortal