Me again! (sorry for asking so many questions...)....
# support
p
Me again! (sorry for asking so many questions...). I'm trying to get telemetry from self-hosted instances, thus those instances need to have the WRITE_KEY, so they can send data to the engine. Is there a way to approach this without sharing the WRITE_KEY? I'm not sure which is the best practice here. Thanks!
b
do you mean
WORKSPACE_TOKEN
you will have a different write_key depending on the source, and depending on technology stack, you treat it as you would any other environment variable
p
uh, I think nope (maybe I'm wrong about it but, AFAIK): • workspace_token is used by rudder-server to get the configuration from rudder cloud • write_key + data_plane_url is used to send telemetry from the clients to the rudder-server
I'm developing a saas + self hosted platform. It's open source and anyone can install in their own clouds / CPDs. For those self-hosted instances, I'd like to get some telemetry (version installed, for instance) so I can email for security updates. Those instances need to have the WRITE_KEY
b
Here is a source, using the ruby SDK, the write key is specific to this source. It's used like any other environment variable. This is a "rails-y way". For my ios source, i use an
Info.plist
,
ohh i see
p
I've seen examples (digging in github) where de dev team kind-of obfuscates the WRITE_KEY during the building process; this obfuscation is not really useful, and in Python in particular, you see...
g
What you are asking for is fundamentally a hard problem (impossible I think :)) You have an open source software which anyone can download and run. However, you don't want people to be able to send telemetry outside of running the software. How do you even remotely verify that they are running the software?
p
uhmmm, yes, may be it was a sillly question; if I got it correctly this is similar to google analytics web scripts, where the track-id is accesible through the browser
Thank you!
g
Not at all a silly question - this is a very valid requirement. I know someone who did a PhD on this topic - how to remotely run authenticated code 🙂 BUt yes, these are not practical solutions