<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by TheArchitect123 on Medium]]></title>
        <description><![CDATA[Stories by TheArchitect123 on Medium]]></description>
        <link>https://medium.com/@dan.developer789?source=rss-b18fb632262f------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*ltcnXWKMdwjO9mBmeOOs9g.png</url>
            <title>Stories by TheArchitect123 on Medium</title>
            <link>https://medium.com/@dan.developer789?source=rss-b18fb632262f------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Mon, 23 Nov 2026 00:54:44 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@dan.developer789/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Security & Architecture of the Terra Payment Gateway]]></title>
            <link>https://medium.com/@dan.developer789/security-architecture-of-the-terra-payment-gateway-9cbe928e7fde?source=rss-b18fb632262f------2</link>
            <guid isPermaLink="false">https://medium.com/p/9cbe928e7fde</guid>
            <category><![CDATA[lunc]]></category>
            <category><![CDATA[payments]]></category>
            <category><![CDATA[luna]]></category>
            <category><![CDATA[crypto]]></category>
            <category><![CDATA[terra]]></category>
            <dc:creator><![CDATA[TheArchitect123]]></dc:creator>
            <pubDate>Sat, 08 Apr 2023 06:48:51 GMT</pubDate>
            <atom:updated>2023-04-08T06:50:03.783Z</atom:updated>
            <content:encoded><![CDATA[<p>This article serves as a detailed overview of how the security of the payment gateway is managed &amp; architecture. This is to increase confidence, trust &amp; some transparency for users who do decide to transact.</p><h3><strong>What problem are we trying to solve?</strong></h3><p>Let’s first discuss the problem that this project solves. The TerraClassic Ecosystem currently lacks the means of allowing companies (FIAT) to integrate with the Terra Ecosystem. For developers in the FIAT world to start transacting &amp; selling their products for Terra, requires deep knowledge of blockchain, gas fees &amp; estimation, management &amp; security of wallets.</p><p>What the payment gateway does is abstract all this knowledge away, so businesses can reduce their need for intellectual capacity, reduce costs, and focus just on delivering their products to the customer.</p><h3><strong>Technical Discussion:</strong></h3><p>Alright let’s get technical.</p><p>There are plans for a custom Terra Wallet that’s compatible with the Payment Gateway. This TerraWallet will allow users not just for communication with Terra, but also for other blockchains too. Especially for the long term, it would be viatle to bring further liquidity to the chain.</p><p>In order for dApps &amp; their customers to conduct a payment on a product, they must have first installed the Payment SDK relevant to their respective platform.</p><p><strong>Currently for users to conduct payments </strong>on the gateway the dApps must pass the seed phrase of the user’s wallet to the gateway. The gateway then uses this to sign transactions and immediately destroys them after use. It does not store the seed phrases, it only acts as a relay between the different platforms for all developers.</p><p>Companies &amp; Businesses using the payment gateway are encouraged not to store the seed phrase, but merely to pass it to the gateway. Upon each launch of the application, the seed phrase is reset &amp; destroyed &amp; the users must reconnect their wallets again. <strong>However companies transacting are responsible for the seed phrase if they do store it &amp; they must protect it just like any other personal information they might collect from their users.</strong></p><p>Devs use the payment libraries based on their platform &amp; configure them for the blockchain.</p><p><strong>Platforms currently supported are:</strong></p><ol><li>C# (Microsoft, .net)</li><li>Flutter &amp; Dart</li><li>Npm</li></ol><p><strong>Game Engines currently supported are:</strong></p><ol><li>Unity3d (available via git link install)</li></ol><p><strong>Platforms for future support:</strong></p><ol><li>Unreal Engine</li><li>Swift (Native iOS &amp; MacOS) via Cocoapods</li><li>Kotlin for Android &amp; Spring</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*wNbPY99qASh-YgA2FvKOGg.jpeg" /></figure><h3><strong>The next layer of security:</strong></h3><p>Nobody trusts an app that asks for a seed phrase. Even when they’ve been told, proven, even guaranteed that the seed phrase is safe &amp; will not be used in any way beyond what was been told. It’s just too risky.</p><p>The next stage of work is to introduce a wallet application, <strong>Terra Authenticator</strong>, that is responsible for managing user wallets &amp; authorizing other applications access to signing transactions on behalf of the user via a token, which is returned back to the calling application.</p><p>Users now will have to install 2 applications for any dApps they use. The first is the dApp itself (product of business they are transacting with) and the <strong>Authenticator App </strong>used to connect their wallets with the dApp.</p><p>The applications no longer pass the seed phrase or ask for it, from the user. They simply ask the user to download the Terra Authenticator and the Authenticator handles 2FA (Two Factor Authentication), token management, generating wallets, so the payment gateway can transact, all in one place.</p><p>When users setup their wallet with the Authenticator, a new record is added to the gateway on its KeyVault (a secure key/value database on backend), where their seed phrase is encrypted with their passcode of choice (stored on the user’s device), and stored there.</p><p>The seed phrases are thus stored on the gateway as encrypted text, where not even the gateway or myself can know how to decrypt it. It’s completely unreadable until the user makes a payment, where the temporary decrypted seed phrase is used, cached, then destroyed after use (after the transaction work is done).</p><p><strong>An example of how the seed phrase will look like when stored on KeyVault:</strong></p><blockquote>MdFoe5+5YmNeAhjtc5QVi18N5tsf/vtAJpZ64cj0I0I2dP0AR1MhcWkOk/kMLc7ZEoAABZUM9Hwsl74PemDp+sHrOSjPeMXk2SUFO0SdcWqK6QL/KFrcSwPCzOJB67ltaO72Hi+efOlEQAPeV/EwmzJ97/r0Fes2LAF2jLLMiFj6pQq/Pv8zyKGzopP/ZqZsarzDiDtTMlinnHc5OVS/wzEjdUKqZwlBlBGtMhfgf00TwSBVgCZgpR3U9uMlKTThL9DiykvavqMfMTNIpdnCHZtKkLDgiJdIZzpQ4HsPIQM=</blockquote><p>Companies that need to authenticate with the <strong>Terra Authenticator</strong>, must register an API Key, which acts as a public key for the Authenticator to identify the company and guarantee it’s a safe app that has been recognized that needs access.</p><p>If it doesn’t recognize the API Key it rejects the call and blocks the app. If it does recognize it, then the user is prompted with a permission to allow the Authenticator to generate a token on behalf of the business app.</p><p>This API key is planned to be generated on my TerraStation Portal, but for now it’s manually generated by me.</p><p>Terra Authenticator works on every platform and allows browsers to authenticate, through a simple 2FA popup. If for example, users are using a web app that needs to make a LUNC/LUNA payment, then they will receive a notification on their mobile device. They allow the permission, if they want to allow the transaction to begin, and the browser receives the response</p><p>If users need to change their passcode, it will destroy the original encrypted seed phrase, and replace it with the newly encrypted phrase.</p><p><strong>Why not just use Terra Station Mobile?</strong></p><p>There are very specific requirements associated with this L2 solution that TerraStation mobile cannot meet.</p><p>The payment gateway is the only system that is responsible for signing transactions &amp; handling payments. Due to the fact that there are many platforms &amp; programming paradigms, in order to simplify development, where the SDKs are only concerned with making a call to transact, it is crucial that the gateway manages all transactions.</p><p>TerraStation Mobile uses a technology called <a href="https://walletconnect.com/"><strong>WalletConnect</strong></a><strong>. </strong>It however is not compatible with a Backend Solution such as this. It only works for Front End Apps (Mobile or Web) &amp; hence Terra Station Web.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2AacgXx9pxOMsu9K8w3LFg.jpeg" /></figure><p><strong>How will users transact now?</strong></p><p>Once dApps have a viable token from the Authenticator, they can then begin to transact. The token contains a symmetric key (the passcode users use to encrypt the seed phrase, when first recovering a wallet on the authenticator).</p><p>This token is a base64 form string, and contains a lifetime for the token (when the token expires the payment SDK then forces the app to reconnect the user’s wallet, reauthentication), and the symmetric key (the passcode used to encrypt the seed phrase). Each token lasts for about a day, before they expire.</p><p>Example of a token: <strong>MTIyNDIxXzAzXzAzXzAz</strong></p><p>The dApp when making a charge on a customer passes this token to the payment gateway, how much they want to charge the customer, the customer’s wallet address &amp; the business’s address, and whether they are charging LUNC or LUNA.</p><p>The gateway then decodes this token, extracts the passcode and uses it to decrypt the seed phrase it has stored on its <a href="https://developers.cloudflare.com/workers/learning/how-kv-works/">KeyVault Storage</a>.</p><p>KeyVault Storage is a secure database of key/value pairs.</p><ol><li>The Key is the terra wallet address (the public address)</li><li>The Value is the <strong>encrypted</strong> <strong>seed phrase </strong>of the customer.</li></ol><p>The gateway takes the seed phrase via the customer wallet, and decrypts it via the token passed from the dApp. It then caches it into a temporary object in code, which is then destroyed after use, after it’s signed the transaction and made the payment on behalf of the customer making the purchase.</p><p>This cycle is repeated as users make further purchases. The same business logic applies as above.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*SeWCUrBQ_9ZCZ-ao_UHIWA.jpeg" /></figure><h3>What’s coming up, new features?:</h3><p>Subscriptions &amp; the new TerraStation. Oh man there’s allot to unpack here. I might reserve this for another article</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9cbe928e7fde" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[The Next Steps for Terra’s Utility & Long term plan]]></title>
            <link>https://medium.com/@dan.developer789/the-next-steps-for-terras-utility-long-term-plan-732091785019?source=rss-b18fb632262f------2</link>
            <guid isPermaLink="false">https://medium.com/p/732091785019</guid>
            <category><![CDATA[lunc]]></category>
            <category><![CDATA[luna]]></category>
            <category><![CDATA[terra-blockchain]]></category>
            <dc:creator><![CDATA[TheArchitect123]]></dc:creator>
            <pubDate>Tue, 07 Feb 2023 08:44:37 GMT</pubDate>
            <atom:updated>2023-03-24T14:02:00.573Z</atom:updated>
            <content:encoded><![CDATA[<p>As you are well aware I’ve been developing payment libraries that allows developers on different programming ecosystems to integrate on-chain payments with their applications/games.</p><p>These payment libraries handle the gas fee (burn tax) calculations, and make it very easy for developers to get started with Terra, by abstracting away knowledge of blockchain as much as possible. Devs just call the payment libraries’ api, and the api handles the rest. Then on-chain activity grows on its own through their own customer aquisition and activity.</p><p><strong>Payment libraries already developed &amp; Ready for Production use:</strong></p><ol><li><a href="https://www.nuget.org/packages/Terra.Net.OnChainPayments">https://www.nuget.org/packages/Terra.Net.OnChainPayments</a></li><li><a href="https://pub.dev/packages/terra_dart_onchain_payments">https://pub.dev/packages/terra_dart_onchain_payments</a></li><li><a href="https://www.npmjs.com/package/terra.onchainpayments">https://www.npmjs.com/package/terra.onchainpayments</a></li><li><a href="https://github.com/TerraMystics/Terra.Unity.Package">https://github.com/TerraMystics/Terra.Unity.Package</a> (GameDevs)</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*42X74s5HYddBZNVovVJeoA.jpeg" /></figure><p><strong>It is crucial that we increase on-chain liquidity.</strong> On-chain effectively just means dApps (basically products from other devs that communicate with the Terra Blockchain) manage all funds, bring funds from exchanges (or outside FIAT sources), and shuffling money back and forth between Terra wallets.</p><p>Without funds running on-chain, there is no utility and no burn tax. Funds that do not run on chain, the community has no control over, and thus means we are at the mercy of big players like Binance.</p><p>We are all thankful to Binance for their help in burning the supply, but we cannot continue pretending to be a viable chain when our only use case is burning the supply. We might as well tell people to buy lottery tickets, and pray &amp; hope price increases.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*t8T03fjGPX4Ow2ZyH4UpNg.jpeg" /></figure><p>Without utility, there is no reason for any blockchain to exist. <strong>We must bring utility, to bring legitimacy to our chain. </strong>And in order to attract the big money, thus increase the price of <strong>LUNC/LUNA</strong>. Remember that at the end of the day (no matter what anyone says), <strong>the only reason why most people do cryptos in the first place is to make money</strong>. Everything else is extra. <strong>Price action is all that matters to the average investor.</strong></p><p>So, me sitting here, and thinking about my place in the universe, with a scotch &amp; a cigar, well minus the cigar…a cuban :). I’ve been thinking, and here’s what I’m planning for the next 6 to 8 months.</p><p>The first steps are to make it easy for dApps to integrate with the Terra Chain. Most applications/games on the market are not Web3 orientated. Meaning they do not use blockchain. We must bring them to our chain, and that means we need a way to migrate FIAT to LUNC/LUNA, painlessly, using the existing infrastructure out there.</p><p>As of now we need a Bank to handle the conversion, and the only middle men that can do this are the Crypto Exchanges. <strong>So we need a way to migrate customer funds from the Exchanges to on-chain customer Terra wallets through the dApps.</strong></p><p>This is where the Exchange Apis come in:</p><p><a href="https://github.com/TerraMystics/Binance.Net.FiatToTerra">GitHub - TerraMystics/Binance.Net.FiatToTerra: (CURRENTLY IN DEVELOPMENT) A lightweight library to manage swaps/withdrawals from fiat to LUNC</a></p><p><strong>Each exchange will have their own SDK and their own target language for the platform of the dApp (Example: Dart for Flutter, C# for .Net, Kotlin for Android).</strong></p><p>Any dApps interested in integrating with the Terra Ecosystem, will first need to prepare their existing customers for on-chain payments. This will be documented on a separate website I’m also developing.</p><p>The Exchange SDKs, will manage this for the dApps. They will check if the users are an existing exchange customer, manage swaps from FIAT to LUNC/LUNA, and handle withdrawals to their Terra Wallets.</p><p>Once funds exist on the customer’s wallet, then the dApps need to configure their payment library. Which requires only 2 parameters, and that’s the <strong>customer’s recovery words </strong>&amp; <strong>the business wallet that will receive the on-chain funds </strong>(the dApp developer’s wallet).</p><p>Recovery words (customer keys) are immediately destroyed after use, and there’s no way for the dApps to persist these keys.</p><p>Unless they fork the library, but recommendations for any dApp developer is to use Azure KeyVault (or some kind of key/value based cloud store), if you insist on storing recovery words. This will be documented as well. <strong>But if you do this, you are responsible for your customer’s keys.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6UfDeZTGz2eRQ5RQ7mQ4MA.jpeg" /></figure><p>dApp developers will be able to deploy on chain payments for any platform, except Apple (if you require the AppStore).</p><p>When it comes to Apple, Apple will not allow on chain payments directly on apps deployed to their store due to the 30% service fee requirement. In order to resolve this, I will be deploying a custom app store specifically for iOS/MacOS devs.</p><p>It’s important and we need to entice and allow dApps from different industries (games, photos, production apps, banking, etc), to bring their users to the Terra Ecosystem.</p><p>Long term, I’m also hoping we can offer discounts on the burn tax, incentives for devs by rewarding them for on chain activity + recognition from the LUNC community.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=732091785019" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>