Hello, may I ask whether the write key can be made...
# support
g
Hello, may I ask whether the write key can be made public? What would happen if it got out? I have written a Golang command line program, the code is open source, I want to integrate your statistics in this command line program, but I see in the code to create the Client needs to write the write key into the code, so that everyone can see my write key, I am a little afraid
šŸ‘€ 1
m
Hey There! šŸ‘‹ Your message has been received by the RudderStack team. Our standard customer support hours are 9-6 PM EST, but we will forward this request to your Technical Account Manager, and they will get back to you shortly. Please use the thread for any additional comments.
g
I @great-photographer-18447, would love to ⭐ your project. Do you mind sharing link to your repo?
Regarding your question,
write_key
is used on the client side, so if your app or cli is public, it will be visible to anyone who uses it. There's nothing much that you can do about it.
q
@great-photographer-18447 You can try to hide the write key inside binary code. storing it as a secret and only adding it to the binary during build time. Some references • https://belief-driven-design.com/build-time-variables-in-go-51439b26ef9/ • https://github.com/rudderlabs/rudder-server/blob/master/.github/workflows/builds.yml#L96 It would still be possible for someone to extract the writeKey from the binary, but much harder
g
I am now injecting at compile time, thank you very much!