Web3 Mini Programs? MetaMask Snaps Explained

24-07-03 22:00
Read this article in 16 Minutes
总结 AI summary
View the summary 收起
Original title: "Web3 Mini Program? MetaMask Snaps Interpretation"
Original source: ZAN Team


MetaMask Snaps


MetaMask Snaps (https://metamask.io/snaps/) is a project with long-term ideals. However, apart from the "ideal" coat it is wearing, the author prefers to call it a mini program in the Web3 world. Or give it a fancy name: dApplet.


As developers, especially developers in China, you should be familiar with its concept. In recent years, we often hear Internet jargon such as "ecological creation" and "super app". Business giants always want to make the Internet more and more closed so that they can transform themselves from the role of service providers to the role of standard setters.


Now, this trend seems to be slowly drifting towards the Web3 field.


Today (June 2024), although Snaps has been around for almost a year, and the concept has been proposed for at least 4 years, ordinary users have almost no knowledge of it. I have some friends who pay close attention to the cryptocurrency market. They open MetaMask every day as naturally as eating and sleeping, but they still don’t even know what MetaMask Snaps are. However, after I explained to them that "it's like a mini program", an indescribable smile always appeared on their faces (they are all developers, most of them are front-end developers).


This scene inexplicably reminds people of the situation when WeChat mini programs first came out. Because the function entrance was not obvious, the usage was very low. Later, after the entrance was changed to a list of mini programs appearing when the homepage was pulled down, the usage began to increase significantly. Since MetaMask wants to build an ecosystem, how to attract users to enter the ecosystem will probably become an important issue that needs to be solved urgently.


Since its emergence, mini programs have been controversial in the Internet industry. Front-end engineers generally sneer at its emergence, believing that it is just a commercial tool for Internet giants to monopolize traffic and block the ecosystem, and it does not contribute much to technological development. I wonder how much Web3 Snaps can contribute to the community? Browsing the documents provided by MetaMask, I feel more and more that future Snap developers will suffer the hardship of dancing with shackles.


It has been nearly a year since MetaMask launched the public beta of Snaps, but the number of available Snaps listed on its official website is actually not very large. As of June 2024, there are only 68 Snaps available. You should know that before the official public beta, as early as around 2020, the official had already proposed the concept of Snaps, and Web3 companies and developers have actually had a long time to fully understand it.


Some Snaps


The author has not seen a developer who specializes in developing Snaps, but there are still many small program developers in Web2 around him. The general view of small programs is that the development experience is relatively poor. Small program development still uses the front-end ecosystem, but it is a castrated version. Manufacturers restrict what developers can actually do for various reasons. In addition, the technical capabilities of various manufacturers and the quality of the documents they provide vary greatly, which means that developers have to step on various strange pitfalls on various platforms before they can be praised as "experienced".


Back to Web3, for security and other reasons, Snaps is very likely to face a similar situation. It has to run in an isolated security context and uses "secure ECMAScript", which actually imposes some restrictions on JavaScript APIs, such as being unable to access DOM, Node.js, browser plug-in APIs, etc.


Due to understandable security considerations, a basic Snaps can't actually do much. Most of its functions require the corresponding permissions first, so Snaps needs to apply for relevant permissions from users when installing. Available permissions include lifecycle, transaction, signature, CRON, etc.:


https://docs.metamask.io/snaps/reference/permissions/#eth_accounts


Therefore, compared with the prosperous Web3 ecosystem, there are very few available Snaps, and MetaMask has classified them.


Snaps Type


According to the classification of MetaMask official website, it can be roughly divided into 4 types:


Account Management


This type of Snaps mainly improves the security of private keys through MPC (Multi-Party Computation, https://blog.usecapsule.com/what-is-mpc/) technology.


Think about how we usually protect our private keys? Probably many people will save their mnemonics somewhere, the author guesses that it is generally on their own computers or mobile phones, haha. Of course, if you are very rich and have a lot of funds in your wallet, then you may indeed use a more confidential method, such as using a hardware wallet. But most people, to be honest, just paste their mnemonics somewhere that they can easily find to avoid forgetting them completely.


This way of saving may cause some problems:


1. If you forget where you put your mnemonics, then you are likely to say goodbye to the assets in your wallet.


2. If the device where you store your mnemonics encounters a Trojan virus, it is difficult to prevent hackers from stealing your mnemonics. Some users may split their mnemonics and store them separately to improve security. This may increase some security, but it will undoubtedly increase the difficulty of management and the risk of forgetting.


MPC technology can automatically split your private key into multiple copies and store them in different places. Only when the private key is needed to sign a transaction, they will be spliced together to generate a complete private key. At the same time, the complete private key will not be generated in this process, which will protect the private key from leakage to the maximum extent.


So far (June 2024), there are only 3 account management Snaps, namely Capsule, Silent Shard and Safeheron.


· Capsule uses the device's PassKey, recovery password, and 2FA to jointly maintain the same key. If one is lost, it can be recovered through the other two.


· Silent Shard and Safeheron achieve this by using multiple devices to install their apps.


It is difficult to say how many Web3 users this type of Snaps can attract. Judging from the data shown on the Snaps website, there are indeed very few Snaps of this type and the installation volume is not high.

They are not complicated to use, so I will not go into details here. After the installation is complete, an additional address will appear in your MetaMask wallet:



Interoperability


This type of Snaps mainly provides compatibility with non-EVM networks. We can see many familiar chains, including Solana, Cosmos, Near, Sui, etc. At present, this type is the most, and they occupy more than half of the entire Snaps ecosystem.


Rich multi-chain Snaps


Notification and Chat Communication


I personally prefer this type of Snaps, but at present, there are so many optional chat applications, and users who are willing to send messages through chains are obviously still a minority. Then unfortunately, we can only continue to "fight for the future".


Security


This type of demand is relatively large, especially since MetaMask itself does not do enough to warn users when they encounter phishing transactions. As the most common operation in the field of cryptocurrency and blockchain, transactions are inherently high-risk and highly sensitive. Through the transaction insight-related functions provided by Snaps, developers can show users more abundant transaction information, provide analysis and insights on transactions, and minimize user asset losses.


A friend of mine has encountered a situation where his account balance was transferred by a phishing website, and MetaMask did not warn him from connecting to the wallet to successfully transferring the money. He had no choice but to switch to another wallet. Moreover, the author did not know much about Snaps at the time, and only recommended ZAN's KYT (https://zan.top/home/know-your-transaction?chInfo=ch_wxdyh) service to protect his transactions. I hope that this type of secure Snaps can make up for the shortcomings of MetaMask itself. In fact, from the data shown on the Snaps official website, secure Snaps are indeed the most in demand besides multi-chain support, currently accounting for 20% of the total.


MetaMask Snaps provides endowment:transaction-insight and endowment:signature-insight permissions to meet relevant needs. After Snap applies for relevant permissions, it can read the payload of the original transaction or signature when the user initiates a transaction or signature. Snap can analyze it and then show users more and richer security instructions.


Idea MetaMask wants to expand its field to other chain platforms through Snaps, but how far it can go in the end is probably difficult to achieve as it wishes. Take the mini-programs in the Web2 field as an example. Although many apps provide mini-program versions, the services provided by the simple mini-programs are often far from comparable to those of apps, and the follow-up of new features is often lagging behind. Many mini-programs even guide users directly to their own apps. After the explosive growth of mini-programs, more apps also want to get a piece of the pie, and have launched their own mini-program platforms. Each company is working hard to strengthen its own moat, and the entire Web world is becoming more and more "centralized".


The capital in the Web3 field is not better than that in Web2. If Snaps develops well in the future, more wallets will inevitably follow. If it really comes to this point, developers in the Web3 field need to develop corresponding versions for the "Snaps" of each wallet, which will probably make them anxious for a while. However, if all manufacturers build their own "Snaps" ecosystem, it is almost equivalent to having no unique ecosystem of their own. Hey, this seems to be in line with their "decentralized" label.


We may be able to predict that there may be various "Snaps-like" in the future, with huge differences in platforms. At this time, compatibility with various platforms has become the daily work of developers, and it has finally reached an unbearable point. So Snaps Standard was born in the expectations of many developers, and there will be various "SIPs" for people to participate in discussions, and the community is prosperous...


I'm sorry that I personally seem to have too little confidence in MetaMask Snaps. In any case, it is at least a product built by a group of passionate developers who want to solve real problems, rather than a scam initiated by a group of financial experts.


However, for most of MetaMask’s current users, Snaps is not really a particularly necessary feature. MetaMask may need to do more work on how to promote it more effectively.


Original link


欢迎加入律动 BlockBeats 官方社群:

Telegram 订阅群:https://t.me/theblockbeats

Telegram 交流群:https://t.me/BlockBeats_App

Twitter 官方账号:https://twitter.com/BlockBeatsAsia

举报 Correction/Report
PleaseLogin Farcaster Submit a comment afterwards
Choose Library
Add Library
Cancel
Finish
Add Library
Visible to myself only
Public
Save
Correction/Report
Submit