Mac App: Protect downloaded video files for offline viewing. - swift

I am building a Mac app that can stream videos, but I would also like to provide offline viewing support. I would let the user download the videos, however, I do not want the video files to be accessible to user.
Is there a way to ensure that the user cannot access the video files? I would like it to behave similarly to how iOS files are stored in sandbox environment and not accessible to users. I have considered encryption/decryption, but am concerned the amount of time to decrypt would be too high due to large size of some of the video files (some over an hour long), leading to bad user experience.

Related

How to save photos and videos from iPhone with exif time data?

I want to get my photos and videos from iPhone on my laptop.
I realized, that I am not able to save with on Mac with Photos app (it adds a sequentially name to the photo..)
and with iCloud there is no option to download all photos together. (Apple-prison).
I found the way after a lot of research and probation:
Workaround 1 - iPhone side
On iPhone with Dropbox app you can upload photos and videos to the cloud, and then you can download them anywhere you wish (even with the free version).
Dropbox is clever enough (not like Mac's Photos app...), to use camera time for naming. So your file names will be a timestamp when you have taken the picture OR video AKA Exif data).
Workaround 2 - desktop machine side
You can use Photos app (on Macbooks), because with cable it is obviously faster than uploading to Dropbox through wifi.
But... Photos app is so "old-school", that when you export photos, it will not use your Exif data as filenames, it will create a sequence, like IMG_6033.mov rather..
images, you can use Exif-renamer app (available in the app-store).
It is free, and it can rename all images in a folder to the timestamp from Exif data.
Unfortunately, it can not rename videos..
https://apps.apple.com/us/app/rename-with-exif/id1469032019?mt=12

What is a good server I can use for uploading / storing videos?

I am making a video sharing app for IOS and eventually will be adding it to the google play store too.
I was previously using firebase for my server to upload videos to, but I ran into some problems and firebase doesn't allow you to upload videos while your app is in the background (at least I couldn't figure it out). So I am switching servers and I would like to get some recommendations from you guys.
Question:
What is a good server / API that I can use to upload and store a lot of videos until they need to be downloaded when a user wants to watch one of them? Videos will be about 10 minutes on average, but they could be as long as 24 hours.

[Flutter]How to download video to app, and make it accessible only through the app (Similarly to Youtube/Netflix)

i'm fairly new to Flutter and is currently working on a course app that requires downloading the videos to the app.
The downloaded video will only be accessible through the app just like Youtube and Netflix, and will be hidden/encrypted from gallery. Would greatly appreciate if someone if someone could point me in the right direction in building this feature.
On iOS and Android your app has it's own isolated folder for storing documents. Items stored there are not intended to be accessible to the user outside of your app. This folder isn't scanned by the Gallery or accessible to other apps on the device. (However, with a little effort a user can access the files so this is not a complete solution where security is an concern. You would need to add encryption if you didn't, say, want a motivated user to copy the video file to a PC and be able to play it.)
the path_provider plugin gives your Flutter app common file locations on a device. The private app folder location is retrieved with getApplicationDocumentsDirectory()
"Download video" is a vague requirement. Most video on the internet (Netflix, Youtube) is provided via HLS or DASH for streaming, which you do download but the video is split up into many files- sometimes thousands of files for a single video. The dart:http package is likely what you're going to want to use to get/download the files (unless the video files aren't available via HTTP/HTTPS, then you'll need a different transport-specific library, like FTP, RTSP, etc.)

Sencha Touch and Saving Local Media

Does anyone know if it is possible to save media from the internet on the local device using Sencha Touch? From what I've seen so far, I understand it's definitely possible to save XML or JSON data locally on the device, but I have had no luck finding ways to store media locally.
To be more specific, I am looking to program an app that provides the user with a series of audio seminars - like podcasts, really. The user would be able to stream those audio files directly from the internet, but I also need to provide the user with the ability to save an episode/seminar for later. This will be important for when a user is traveling and does not have a reliable internet connection or data plan.
The primary delivery device would be on iOS (iPhone, iPad, iPod Touch) and I would hope to be able to use the same technology on Android devices - but that would be a secondary phase.
If this is possible, how would I go about saving material? And what, if any, would be the limitations on doing so? Any thoughts on this would be greatly appreciated.
I have done something similar using Sencha Touch 1 and PhoneGap to produce a hybrid app.
Basically, I use Sencha Touch to download the JSON, etc and LocalStorage to hold the data. Downloading media/files/etc to the actual device is not supported in Sencha Touch as the framework doesn't have access to a file system.
I then use PhoneGap's API's to tap into the device's native file system and download files to the app's Documents directory and pass the file names/paths to Sencha Touch for use in the app.
I'm assuming you are looking to create a hybrid app based on your question but if this is strictly a web app then there isn't much you can do.
TO add to the above point, you possibly could base64 encode the file and store it within LocalStorage but this isn't a sustainable model as LocalStorage only gives you 5mb of space. If you go over 5mb, the user is prompted (yes, no) to allow LocalStorage to use more space (in 5mb increments). Since the files your reference have the potential to be 5mb each, you can see how this could quickly become unmanageable for both you and the user.
EDIT:
See http://phonegap.com/ for the native wrapper
http://blog.clearlyinnovative.com/post/2056122828/phonegap-plugin-for-downloading-url-all-the-code for the phonegap download plugin
and https://github.com/aaronksaunders/FileDownLoadApp for the code
Check this website out. Scroll down to storing data offline. They discuss Sencha Touch provides a set of data store and proxy classes that make it very easy to work with data from (and going to) a variety of sources - both server- and client-side... hope this helped, cheers.

placing video files on http from my local computer

I am making one application in which I need to play some videos on my webpage or application.
And my videos are placed on my computer locally. Now what kind of URL i need to provide, or what type of streaming do I need to make it playable on other computers, from the webpage only.
Is there any controls, which plays videos locally on my computer and show it to the client side.??
Thanks in advance.
First of all is your web site hosted on your computer or are using a Hosting service?
Either way
You can use either flash Plug in or Windows Media Player Plugin
(silver light is also an option, the risk is the users may not have installed it since it is fairly new)
you must configure them with the URL of the videos, so that they will be served for viewing
Eg:
while doing that place your videos in a seperate folder in the site's root folders
like /videos/video1.mpg