You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I can't figure out how to generate this? Should I use the guide on the official documentation link: https://core.telegram.org/mtproto/auth_key or is there another way to do this? thanks
The text was updated successfully, but these errors were encountered:
You can get RSA keys from here. Just save all public keys of your app into single file, and add path in configs.
To be honest, you need just first RSA public key, i don't know yet, what the purpose of other keys. but i think they are need to make requests to telegram CDNs or something like this. Just save ALL keys, we'll update this lib when we understand, why do we need other public keys)
Also, I suppose to add ENV files to the project. For example, if I changed the PATH into .pem keys, they otherwise already hardcoded in init() function on the telegram/common.go:
func init() {
keyfile := "~/go/src/github.com/xelaj/mtproto/keys/keys.pem" // HERE IS CHANGE TO os.Getenv("MTPROTO_KEYS_PATH")
TelegramPublicKeys, err := keys.ReadFromFile(keyfile)
dry.PanicIfErr(err)
choosedKey := dry.RandomChoose(dry.InterfaceSlice(TelegramPublicKeys)...).(*rsa.PublicKey)
_ = choosedKey
}
@rglitchard oh crap, i supposed that i fixed it already)))
enviroments are bad in vendor libs, but idea is good. Also, check out this branch, i'll soon merge it into master, it has multiple fixes of client, and has NewClient constructor, you can add path in params
Hello, @ololosha228. Thanks a lot for this library, can you please clarify how I can generate mtproto keys from your example?
I can't figure out how to generate this? Should I use the guide on the official documentation link: https://core.telegram.org/mtproto/auth_key or is there another way to do this? thanks
The text was updated successfully, but these errors were encountered: