~AreEnn
                        
                        
                            ~R4SAS
                        
                        
                            ~acetone
                        
                        
                            ~orignal
                        
                        
                            ~villain
                        
                        
                            &N00B
                        
                        
                            +Xeha
                        
                        
                            GFW
                        
                        
                            Ken_
                        
                        
                            Nobody
                        
                        
                            Opax
                        
                        
                            WebClient95
                        
                        
                            anon
                        
                        
                            anontor
                        
                        
                            anonuser
                        
                        
                            b3t4f4c3
                        
                        
                            deserving-stegosaur
                        
                        
                            duanin2
                        
                        
                            fidoid
                        
                        
                            fujifilm
                        
                        
                            gobo
                        
                        
                            halloy1341
                        
                        
                            iiii
                        
                        
                            karamba_i2p
                        
                        
                            leopold
                        
                        
                            mareki2p
                        
                        
                            negative_rock127
                        
                        
                            nik0tr
                        
                        
                            not_bob_afk
                        
                        
                            ntty
                        
                        
                            osoznayka
                        
                        
                            poriori
                        
                        
                            profetikla
                        
                        
                            rc13
                        
                        
                            shaye
                        
                        
                            slfd
                        
                        
                            sonya
                        
                        
                            teeth
                        
                        
                            un
                        
                        
                            weko_
                        
                        
                            КрутыеЖиды]]]]]]]]]]]]]
                        
                    
                    
                        weko
                    
                    
                        orignal: я не шарю за c++, что из себя представляет m_PublicKey
                    
                
                
                    
                        weko
                    
                    
                        Это в Blinding.cpp 198-212
                    
                
                
                    
                        weko
                    
                    
                        Основная задача из base64 получить b33, пишу на питоне
                    
                
                
                    
                        orignal
                    
                    
                        так посмотри в Blinding.h
                    
                
                
                    
                        orignal
                    
                    
                        std::vector<uint8_t> m_PublicKey;
                    
                
                
                    
                        orignal
                    
                    
                        auto len = identity->GetSigningPublicKeyLen ();
                     
                
                
                    
                        orignal
                    
                    
                        m_PublicKey.resize (len);
                    
                
                
                    
                        orignal
                    
                    
                        memcpy (m_PublicKey.data (), identity->GetSigningPublicKeyBuffer (), len);
                     
                
                
                    
                        orignal
                    
                    
                        короче это публичный ключ подписи из адреса
                    
                
                
                    
                        orignal
                    
                    
                        бывает разной длины 
                    
                
                
                    
                        orignal
                    
                    
                        но на практике он всегда 32 байта
                    
                
                
                    
                        orignal
                    
                    
                        ибо там или EdDSA или RedDSA
                    
                
                
                    
                        weko
                    
                    
                        Вот написал я в сэм DEST GENERATE, получил публичный и приватный, как мне получить из них
                    
                
                
                    
                        orignal
                    
                    
                        надо декодировать публичный
                    
                
                
                    
                        orignal
                    
                    
                        ключи подписи будет по смещению (256+128) - 32
                    
                
                
                    
                        orignal
                    
                    
                        разумеется генерившь EdDSA
                    
                
                
                    
                        weko
                    
                    
                        И получаю то публичный ключ?
                    
                
                
                    
                        weko
                    
                    
                        И получаю публичный ключ?
                    
                
                
                    
                        orignal
                    
                    
                        B33 строится из пбуличного
                    
                
                
                    
                        weko
                    
                    
                        Да, это пон
                    
                
                
                    
                        weko
                    
                    
                        Что значит (256+128) - 32
                    
                
                
                    
                        orignal
                    
                    
                        смещение от начала
                    
                
                
                    
                        weko
                    
                    
                        Угу
                    
                
                
                    
                        weko
                    
                    
                        У меня с 352 байта вышло 30 байт, верно?
                    
                
                
                    
                        orignal
                    
                    
                        там длина должна быть 391
                    
                
                
                    
                        weko
                    
                    
                        Сейчас попробую понять, что я делаю не так
                    
                
                
                    
                        orignal
                    
                    
                        я тебе скажу что
                    
                
                
                    
                        orignal
                    
                    
                        в i2p не стандартный base64
                    
                
                
                    
                        weko
                    
                    
                        Да, сейчас сделаю
                    
                
                
                    
                        weko
                    
                    
                        39 байт с 352-го
                    
                
                
                    
                        weko
                    
                    
                        Всего 391 байт
                    
                
                
                    
                        orignal
                    
                    
                        правильно
                    
                
                
                    
                        orignal
                    
                    
                        там 7 байт сетификат в конце
                    
                
                
                    
                        orignal
                    
                    
                        256 кллюч шфиррования и 128 подписи
                    
                
                
                    
                        orignal
                    
                    
                        но если клоюч подписи короче то он выравнивается к концу
                    
                
                
                    
                        weko
                    
                    
                        И это m_PublicKey, верно?
                    
                
                
                    
                        orignal
                    
                    
                        да
                    
                
                
                    
                        orignal
                    
                    
                        это 32 байта публичного ключа подписи
                    
                
                
                    
                        orignal
                    
                    
                        из него делается b33
                    
                
                
                    
                        weko
                    
                    
                        Спасибо
                    
                
                
                    
                        weko
                    
                    
                        Ура, я сделал
                    
                
                
                    
                        orignal
                    
                    
                        отлчино
                    
                
                
                    
                        weko
                    
                    
                        Правильно понял, что если подпись 7, то blinded 11
                    
                
                
                    
                        weko
                    
                    
                        А в остальных случаях одна и та же
                    
                
                
                    
                        weko
                    
                    
                        ?
                    
                
                
                    
                        orignal
                    
                    
                        blinded всегда 11
                    
                
                
                    
                        orignal
                    
                    
                        он может получиться или из ориганальной 7 или 11
                    
                
                
                    
                        orignal
                    
                    
                        другие варианты счас не реалихзованы
                    
                
                
                    
                        weko
                    
                    
                        А в чём разница между 7, 11 и 11, 11
                    
                
                
                    
                        orignal
                    
                    
                        разная схема подписи
                    
                
                
                    
                        orignal
                    
                    
                        в 7 в качетсве приватного ключа используется хэш от ключа
                    
                
                
                    
                        orignal
                    
                    
                        потому он не годится
                    
                
                
                    
                        orignal
                    
                    
                        в 11 же используется сам ключ
                    
                
                
                    
                        ian
                    
                    
                        Hello I hope you are all doing well, I'm new here. I have a problem, I'm trying to use libi2pd in my own app, after i2p::api::StartI2P(); in my C++ code, what do I have to do exactly? How can I make it connect to network for a while so that connections work? Thanks :)
                    
                
                
                    
                        orignal
                    
                    
                        you must create local destination first (file Destination.cpp)
                    
                
                
                    
                        orignal
                    
                    
                        there you have methods like CreateStream
                    
                
                
                    
                        orignal
                    
                    
                        StartI2P starts your node, netdb and trsnports
                    
                
                
                    
                        ian
                    
                    
                        Okay thanks I see, I need to use i2p::api::CreateLocalDestination first? The old code in anci2pd is still useful to get an idea of this?
                     
                
                
                    
                        orignal
                    
                    
                        тno
                    
                
                
                    
                        orignal
                    
                    
                        just new ClientDestination
                    
                
                
                    
                        orignal
                    
                    
                        or new RunnableClientDestination
                    
                
                
                    
                        orignal
                    
                    
                        yes, code from anci2pd should work
                    
                
                
                    
                        orignal
                    
                    
                        although more pearas and crypto
                    
                
                
                    
                        ian
                    
                    
                        Oh kk I see, thanks alot for helping bro. I'll ask here again whenever I run into issue.
                    
                
                
                    
                        orignal
                    
                    
                        the problem that nobody uses it ))
                    
                
                
                    
                        ian
                    
                    
                        Yea, more apps need to use it. Sadly they don't :(
                    
                
                
                    
                        whothefuckami
                    
                    
                        Sadly?
                    
                
                
                    
                        whothefuckami
                    
                    
                        Yeah sadly
                    
                
                
                    
                        orignal
                    
                    
                        no interest to it
                    
                
                
                    
                        whothefuckami
                    
                    
                        What's libi2pd bts?
                    
                
                
                    
                        whothefuckami
                    
                    
                        Btw
                    
                
                
                    
                        whothefuckami
                    
                    
                        Wong typeing
                    
                
                
                    
                        ian
                    
                    
                        whothefuckami, libi2pd is a library to use inside your own apps, so you can use i2p inside your app.
                    
                
                
                    
                        whothefuckami
                    
                    
                        Eh?
                    
                
                
                    
                        whothefuckami
                    
                    
                        Api?
                    
                
                
                    
                        ian
                    
                    
                        Yeah
                    
                
                
                    
                        whothefuckami
                    
                    
                        Or building part of i2pd into your app?
                    
                
                
                    
                        ian
                    
                    
                        It's so you can interact with i2p network inside your app bro
                    
                
                
                    
                        orignal
                    
                    
                        you can run a built in i2p router in your app
                    
                
                
                    
                        orignal
                    
                    
                        hence you don't need SAM or tunnels or I2CP
                    
                
                
                    
                        orignal
                    
                    
                        you can call CreateStream directly
                    
                
                
                
                    
                        orignal
                    
                    
                        and use this stream it in your code
                    
                
                
                    
                        whothefuckami
                    
                    
                        Exactly what I imagined
                    
                
                
                    
                        whothefuckami
                    
                    
                        Disadvantages?
                    
                
                
                    
                        whothefuckami
                    
                    
                        Can 2 routers be part of network with 1 ip address?
                    
                
                
                    
                        orignal
                    
                    
                        disadvantage that every app has own router
                    
                
                
                    
                        orignal
                    
                    
                        yes, you can do it
                    
                
                
                    
                        whothefuckami
                    
                    
                        I mean
                    
                
                
                    
                        orignal
                    
                    
                        but if you have too many it will look suspicious
                    
                
                
                    
                        whothefuckami
                    
                    
                        Omegapog for creating rats that work through i2p
                    
                
                
                    
                        whothefuckami
                    
                    
                        Super anonymous rat
                    
                
                
                
                    
                        orignal
                    
                    
                        also before i2p consumed severe amount of roureces
                    
                
                
                    
                        orignal
                    
                    
                        but not now
                    
                
                
                    
                        weko
                    
                    
                        Как и обещал  codeberg.org/weko/i2plib-fork
                    
                
                
                    
                        orignal
                    
                    
                        а чего не на гитхабе?
                    
                
                
                    
                        weko
                    
                    
                        Приложение для gitea GitNex получше выглядит (для меня)
                    
                
                
                    
                        weko
                    
                    
                        Да и гитхаб майкам принадлежит, говорит о многом
                    
                
                
                    
                        ian_
                    
                    
                        orignal, can you please write to me the control flow of libi2pd, how it needs to be called in order? Just so I have an idea like LoadPrivKeys->ClientDestination etc.. < I Just made this up Thanks.
                     
                
                
                    
                        orignal
                    
                    
                        first you need to have your local address, e.g. private keys
                    
                
                
                    
                        orignal
                    
                    
                        you can generate them, read from file, etc.
                    
                
                
                    
                        orignal
                    
                    
                        once you have it you create ClientLocalDestination
                    
                
                
                    
                        orignal
                    
                    
                        with these keys
                    
                
                
                    
                        orignal
                    
                    
                        and list of params you might need to set
                    
                
                
                    
                        orignal
                    
                    
                        now you are ready to connect to your peer
                    
                
                
                    
                        orignal
                    
                    
                        once yoy know thier I2P address you call CreateStream and pass idenhash that's basically decoded .b32 address
                    
                
                
                    
                        ian_
                    
                    
                        Then with CreateStream I can do whatever I want?
                    
                
                
                    
                        orignal
                    
                    
                        it's async call
                    
                
                
                    
                        ian_
                    
                    
                        Yea, I need to use boost asio with it bro?
                    
                
                
                    
                        orignal
                    
                    
                        and pointer to new stream will be passed to your callback
                    
                
                
                    
                        orignal
                    
                    
                        i2pd uses boost
                    
                
                
                    
                        ian_
                    
                    
                        Okay good, thanks alot for the help, it's appreciated haha
                    
                
                
                    
                        ian_
                    
                    
                        Hi original, sorry if I'm asking alot tips since there's no documentation. About m_Keys = i2p::data::CreateRandomKeys();, where do I need to store the keys exactly as I want to use same keys later in the same C++ app?
                     
                
                
                    
                        ian_
                    
                    
                        is there a function to save the keys in the good format?
                    
                
                
                    
                        orignal
                    
                    
                        there is no such function
                    
                
                
                    
                        orignal
                    
                    
                        size_t ToBuffer (uint8_t * buf, size_t len) const;
                    
                
                
                    
                        orignal
                    
                    
                        of PrivateKeys
                    
                
                
                    
                        orignal
                    
                    
                        you dump keys to a memory buffer
                    
                
                
                    
                        orignal
                    
                    
                        then save this buffer in file or send by network or whatever you wish
                    
                
                
                    
                        ian_
                    
                    
                        Okay thanks, that's exactly what I wanted.
                    
                
                
                    
                        orignal
                    
                    
                        the opposute is size_t FromBuffer (const uint8_t * buf, size_t len);
                    
                
                
                    
                        orignal
                    
                    
                        you can also save and restore it as base64 string
                    
                
                
                    
                        ian_
                    
                    
                        m_Keys.ToBase64() like this ,it's gonna give base64 yeah?
                    
                
                
                    
                        orignal
                    
                    
                        yes
                    
                
                
                    
                        orignal
                    
                    
                        for SAM for example
                    
                
                
                    
                        ian_
                    
                    
                        alright good
                    
                
                
                    
                        australian
                    
                    
                        Australian government to adopt I2P.
                    
                
                
                    
                        ian_
                    
                    
                        What is the difference between : i2p::data::CreateRandomKeys(); andi2p::data::PrivateKeys::CreateRandomKeys();? The second lets you set custom encryption type? That's the only difference?
                     
                
                
                    
                        weko
                    
                    
                        australian: what?
                    
                
                
                    
                        R4SAS
                    
                    
                        orignal: ghjcnj jndfk
                    
                
                
                    
                        R4SAS
                    
                    
                        просто отвал
                    
                
                
                    
                        R4SAS
                    
                    
                        ща корку скину
                    
                
                
                
                    
                        orignal
                    
                    
                        ха
                    
                
                
                    
                        orignal
                    
                    
                        у меня такая же проблема 
                    
                
                
                    
                        orignal
                    
                    
                        счас чинить буду
                    
                
                
                    
                        R4SAS
                    
                    
                        это релизный пакет
                    
                
                
                    
                        R4SAS
                    
                    
                        если что