Interesting, looks like they might be using a completely different file format for iOS versus Android. In any case, I’ve knocked up a script which will extract the track.ogg file from any pack of your choosing. Pasting directly here to see if it works (haven’t tried sharing code on Lemmy).
You can browse available packs using the below URL. If you want to find out a pack name, just copy the banner image URL for it and you’ll see the “com.whatever” name in the URL itself.
http://www.naturespace.com/android/v3/store/?live=true&udid=0
Code:
import sys
import requests
import hashlib
import io
import zipfile
ns_baseurl = "https://s3.amazonaws.com/naturespace/kindle_catalog/"
# Encryption key
key = b'DE2#We@(# sffsFSHfssfhsSFHSs_+&Gaa s,W.Z./lSFGSDF! NOWG!fjasdflasdkfjSADFKJASdflskgj fdkaG8HS42dncuFFSe=-56a'
def decryptNS(content):
x = 1025
y = 0
dec = bytearray()
for i in range(x,len(content)):
if ((i+1024) % 1024) != 0:
dec += bytes([content[i] ^ key[y % len(key)]])
y = y+1
return dec
if __name__ == '__main__':
if len(sys.argv) < 2:
print("Please provide a pack/module name (e.g. 'com.HolographicAudioTheater.Naturespace.TheImaginarium')")
sys.exit(0)
pack = sys.argv[1]
json_url = ns_baseurl + pack + "/data.json"
size = requests.get(json_url).json()["packageSize"]
print(size)
hashval = hashlib.sha1((pack + "8DvJx25sXwNwq2p" + size).encode()).hexdigest()
dlurl = ns_baseurl + pack + "/" + hashval + "/" + pack + ".nzp"
print(dlurl)
content = decryptNS(requests.get(dlurl).content)
"""
with open(pack + ".zip", "wb") as f:
f.write(content)
"""
zipf = io.BytesIO(content)
zipfile = zipfile.ZipFile(zipf, 'r')
track_nsp = zipfile.read('track.nsp')
track_ogg = decryptNS(track_nsp)
with open(pack + "_track.ogg", "wb") as f:
f.write(track_ogg)
I would say you’re referring more to complexity than determinism. More variables increases complexity but doesn’t necessarily decrease determinism. It depends on whether you believe some of those variables include true randomness though. For example, does quantum randomness affect anything? We’re led to believe it has no real effect on a macroscopic scale, but perhaps over a large enough amount of time and across a large enough set of variables the effect becomes noticeable. If that’s the case, determinism breaks down.