DSS 2026 — Web3 Security Monitoring System Internals Raj Kumar · Sabanaku77 Source video: https://www.youtube.com/watch?v=LElKbG3lGjE Automatic captions — not human-reviewed. Complete spoken-audio coverage is unverified. Source language tag: en (English). Source export SHA256: 921ed2430d5da17b1f2a6107a9d431556de7dbbbf68087f525c2c0b5143f1cf9 [0:00] I'm Rajkumar and I'm a security [0:02] researcher at Celer. The topic of the [0:04] talk today is monitoring system [0:06] internals from on-chain data to incident [0:09] response and I will be giving this talk [0:12] with my co-speaker Prajwal Singh. [0:14] >> Hey myself Prajwal. I work as a senior [0:17] threat researcher for Zscaler and my [0:19] area of interest in Web3 cryptography [0:21] and mainly the monitoring systems. What [0:23] do you Raj? So now Raj is going to [0:25] explain you what are all the topics we [0:29] are going to cover in this talk. [0:32] >> So what we have done is we have divided [0:34] this talk into multiple parts. First we [0:36] will explain why we need monitoring. [0:38] Second one is system architecture behind [0:40] the monitoring system and third one and [0:43] fourth one is about the detection rules [0:45] and the incident response and then we [0:47] will take the case study of Wasabi and [0:49] then of course references and the Q&A. [0:53] So why we need monitoring? So basically [0:56] if we are doing let's say testing, we [0:58] are doing formal verification and we are [1:00] doing manual audits. [1:02] So why we need monitoring system? So [1:05] there is always a possibility that in [1:07] the production our first can [1:10] you know assumption can break and audits [1:12] manual audits are also time bound. So [1:15] there there is a possibility that there [1:17] might be a critical in a protocol that [1:20] can cause basically huge loss to the [1:22] protocol. And basically we would what we [1:25] would like is we would like to detect [1:26] that [1:28] risk and take action against [1:32] against that risk. [1:33] So yeah you can take it from here. [1:35] >> Okay so now I'm going to explain what's [1:38] the monitoring system architecture looks [1:40] like. So we'll start from the left side. [1:43] So first we take input data. You can say [1:46] input logs from two sources. First is [1:48] block data that is the transaction which [1:51] have already been happened. Second is [1:54] the pending transactions most of the [1:56] times from the mem pools. [1:58] Then after getting that data we to [2:01] decode and enrich it because the data is [2:03] in the hex format and making a detection [2:06] rule on a hex hex format is not so much [2:08] useful. After decoding and enriching [2:11] data, we then pass it into Elk stack. So [2:13] basically Elk stack [2:15] is a [2:17] Elk stack is a system where we can store [2:20] the data in decoded form [2:23] and then store store the data in decoded [2:26] form, index it, search it and write the [2:29] detection rules. So on basis of the data [2:32] which we [2:33] stored in Elk stack, we can make [2:35] detection rule on top of that and on the [2:37] basis of the detection rules or the [2:38] cluster of the detection rules, we can [2:42] take response or actionable items based [2:45] on the based on that. [2:47] So let's talk about block data and [2:49] mempool data and how they are different [2:52] and why we need to treat them [2:54] differently when you're talking about [2:55] the monitoring. [2:56] The first thing is confirmed [2:59] transactions, that is block data. So [3:01] when we are retrieving block data, that [3:03] means confirmed transactions from a [3:05] node, it will give us a receipt logs [3:08] because the transaction is already been [3:10] completed. That means we will get all [3:11] the events that has been emitted, the [3:14] state change which occurred due to the [3:16] that transaction. On the other hand, we [3:18] have pending transaction, mostly [3:21] mempool transaction. So basically [3:22] mempool transactions are not executed [3:25] yet. So we won't get the receipt logs, [3:27] that is we won't get the emitted events, [3:29] what what will be the state change, what [3:31] will be the new state. [3:33] So in order to get the same, we need to [3:36] simulate the [3:39] pending transaction which we have it [3:41] from the mempool. So [3:43] while the mempool is important because [3:46] mempool [3:47] gives us time. For example, if we see [3:50] any [3:51] possible exploit or possible things [3:55] which is gonna exploit [3:58] protocol. So in that case, we might be [4:00] able to if we detect it very early, we [4:02] might be able to front run the [4:04] transaction and may be save a protocol. [4:07] Next is basically after getting the logs [4:10] after getting the those logs from [4:12] block data or mempool, what is the next [4:14] step? So basically as I said that data [4:17] is in hex format and we will not be it's [4:19] not much meaningful to make detection [4:21] rule on top of that. So after getting [4:24] the block data or after getting all the [4:27] like data we have we get after [4:30] simulating the [4:31] mempool transactions, we basically refer [4:34] to four data sources. First is receipt [4:37] and logs that are basically the events. [4:39] Second is call traces. They are internal [4:43] contract calls. They don't emit logs. [4:45] Third is basically state change and then [4:48] moving further to ABI and policy [4:50] content. So you can look at the right [4:53] side that the data has been decoded and [4:56] enriched. So we get this in a beautiful [4:59] JSON format. Here we can see okay the [5:01] chain ID is one. This is the block hash. [5:03] This is the transaction hash. Log index [5:05] is seven. Role event is role granted and [5:09] similarly the mode is observed and [5:11] policy version is version 12. [5:13] So after getting so till now we got the [5:17] data. We gripped the data. We enriched [5:19] and decoded, changed it into the JSON [5:20] format. So what next? The next is [5:23] basically [5:25] injecting that data [5:28] indexing it [5:29] and making it prepare [5:32] so that we can write detection rule on [5:33] the same [5:34] and take different actions. So for that [5:37] we have used ELK stack. [5:40] There are other [5:42] other sources too which can be used for [5:44] example Splunk, Microsoft Sentinel or [5:46] Google SecOps. That depends on the [5:48] depends on [5:49] protocol to protocol. So after getting [5:52] the logs in JSON format, what we do? [5:54] We [5:55] we use logstash. So basically logstash [5:58] what it do? It take the JSON format and [6:02] then [6:03] rectify [6:04] the [6:06] rectify the data on the basis of what is [6:10] required. For example, we are getting a [6:12] data in JSON format and we don't want [6:14] certain type of fields or maybe certain [6:16] types of fields are sensitive. We can [6:18] directly remove it. So basically what [6:20] Logstash does to it take the data, [6:22] rectify it, change it in into a unified [6:25] schema and then forward it to the [6:27] Elastic stack. So in Elastic stack what [6:29] happened the same data get stored and [6:32] index. [6:34] Index because [6:36] yeah index so for the fast search. So [6:38] once the data gets stored and indexed in [6:40] Elastic search [6:42] then we will move forward to the Kibana. [6:44] So Kibana is basically a graphical user [6:47] interface which help us in order to get [6:50] logs from the Elastic search that will [6:52] be a lifetime live live data, historical [6:56] data, [6:57] yeah anything. So Kibana gives us a good [7:01] control to any security analyst who is [7:03] sitting there and wants to [7:05] maybe monitor the events or write the [7:07] detection rule based on same. [7:11] So now next we have certain now we have [7:14] got the data [7:16] encoded it, enriched it and then feed it [7:19] into the ELK stack. So now Raj will [7:22] explain what are detection rules and how [7:24] to make it. [7:25] >> So yeah what are detection rules and [7:29] basically to detect everything like [7:31] every type of risk internal or the [7:33] external we need some rules based on the [7:36] threat [7:38] that we were thinking about and based on [7:41] the detection rules we can also write [7:44] the [7:46] incident response for that. [7:48] and the approach for [7:51] writing the detection rule is like [7:53] pretty simple. We can think about [7:56] detection rules in three questions. The [7:58] first one is what can go wrong? Let's [8:00] say if there is a trust assumption that [8:02] we were making it can break in the [8:03] production and if there is a security [8:06] property or intended behavior but that [8:08] can fail in the you know other end time. [8:11] And the second question it is like what [8:13] we will observe basically the detection [8:14] rule and when we will [8:17] basically use that. And third one is [8:20] what action can it still help if we have [8:22] the detection rule, but if we don't have [8:24] the action that we can take then there [8:25] is no [8:27] no worth to write the detection rule, [8:29] right? [8:31] Now for writing the detection rule we [8:34] can use the systematic approach which is [8:36] we can take help from the threat model. [8:38] And for writing the threat model we can [8:42] use a 4A model which is [8:44] we have to map everything in the [8:46] protocol like assets and the invariants, [8:49] assets [8:51] like everything that can [8:53] every like assets that we have and the [8:55] invariants that can break in the let's [8:57] say production. [8:58] And second one is actors and the roles [9:01] let's say we have a role abuse etc. [9:04] So we have to detect that as well. And [9:07] third one is the internal assumptions or [9:09] external assumptions that can [9:12] break in the future let's say [9:13] liquidations or the keepers etc. [9:16] And fourth one is the attack vectors. [9:19] And we we have to take about think about [9:22] every attack vectors and according to [9:24] that we have to write the detection [9:26] rules and for every detection rules we [9:28] have to write the incident response. And [9:31] we can divide risk into internal and the [9:34] externals for internals like accounting [9:37] bugs, role abuse etc. And externals are [9:40] mostly the assumptions that we are [9:41] making let's say DPE Oracle failure or [9:44] compromised signers. [9:47] Yeah, here is a example of the vault [9:50] theft let's say we have a vault user can [9:52] deposit the asset and means that here. [9:54] And [9:56] what we can do to detect that there is a [9:59] theft of the funds. [10:00] Basically we can use the invariant which [10:03] is the if if there is a drop in the [10:06] share [10:07] price it means that something is wrong [10:09] with the [10:10] and if we detect this, it means we have [10:13] to take the action as well, which is the [10:15] incident response. [10:18] Yeah, next part is about the incident [10:20] response. So if we have the detection [10:22] rules, but we don't have a book for the [10:24] actions, you know, like what we will do [10:27] when something goes wrong, then there is [10:29] no mean to write the you know, detection [10:31] rule. So we can take [10:33] action according to the [10:35] So basically we can take action [10:36] according to the protocols and [10:40] the rule that we have written, right? [10:42] And it can be like alerting the team, [10:44] pausing the protocol or disabling a [10:46] strategy and basically [10:50] including the you know, circuit breaker [10:52] etc. [10:53] So yeah. And next there is an example of [10:57] Wasabi hack which will Press will [10:58] explain. [11:00] >> So let's talk about the Wasabi. It's a [11:02] real life [11:04] example that why we need monitoring and [11:06] threat detection. So what happened with [11:08] Wasabi that they got exploited for 5 [11:11] millions over three chains, [11:13] Ethereum base and Blast. So the attack [11:15] vector was pretty simple. It was a [11:17] developer key leak. So this key had [11:22] authority of granting admin rights to [11:24] anyone, [11:25] changing, moving the funds of vaults to [11:28] any other strategies and third is [11:31] basically updating the pool contract. So [11:34] basically what happened the once the [11:37] malicious actor got the private key, [11:39] first he [11:41] granted the admin access to one of his [11:44] contracts. After that he changed he [11:48] moved the fund of vaults by changing the [11:52] strategy. And next what he has done, he [11:55] upgraded the pool contract in order to [11:57] move funds from the same. [11:59] So [12:01] the next question is how and at what [12:04] point we could have detected it. So the [12:07] first point is basically admin grant. [12:10] If an admin access has been [12:14] to a contract or to a address which is [12:16] not in the white list, that's a first [12:18] red flag. [12:19] Next is basically [12:21] strategies. I guess in most of the firms [12:24] the strategy which will be deployed for [12:28] any vault will go through governance and [12:30] have certain kind of approvals. So if a [12:33] vault is redirected to any strategy [12:35] which is not [12:37] white listed or which is not approved, [12:39] that's still a red flag. [12:41] The next next is basically the third [12:44] step that is the pool contract has been [12:47] updated upgraded. So when we have to [12:50] upgrade a contract in any protocol, we [12:52] go through multiple security audits [12:54] other things and certain kind of [12:55] approval. So if a pool contract is been [12:59] upgraded to a unknown contract that [13:01] itself a malicious. [13:03] So in terms of Wasabi, the first [13:06] reported signal was at 7:46. [13:09] Admin was granted at 7:48 and the first [13:11] fall drain was 7:49. So as we can see [13:13] there is a one minute difference between [13:16] admin grant and first wall drain. That's [13:18] enough in order to have a successful [13:22] or we can say a good incidence response. [13:25] Also incidence response in this case [13:26] depends on many factor depends on what [13:29] kind of if they have multiple role [13:31] separation that is role is been granted [13:34] for pausing the contract and etc. [13:37] So I guess [13:41] Okay, so thank you. That's was the talk [13:44] by me and Raj. These are the references [13:46] which I have used for the talk. [13:48] And yeah, we are open to any questions. [13:50] Thank you. [13:53] >> Thank you so much everyone for listening [13:54] the talk. [13:56] >> Thank you. [13:58] >> Okay, okay. [13:59] >> Yeah, yeah, yeah, please. [14:07] >> Okay, that depends on the blast radius. [14:09] For example, that depends on protocol to [14:11] protocol and blast radius. For example, [14:13] in this case, if a vault if you get to [14:15] know the admin right have been [14:16] transferred and there will be effect on [14:18] the vault. So, in that case, it will be [14:20] good to just pause the vault and keep [14:22] the protocol as you know, working. [14:26] It's automated exactly because we don't [14:29] have much time to response when we [14:32] detect something, right? Because [14:33] everything moves so fast. So there is I [14:35] don't think there will be a good option [14:37] to you know, human intervention and [14:39] taking some kind of [14:40] like authorities and all. So everything [14:42] should be necessary. [14:46] Yeah, right. [14:48] Exactly. These are pre-vetted rules [14:50] which we made and we tested out in dev [14:52] in moment. So everything is automated. [14:55] Yeah. [14:55] >> Basically for every detection rule, we [14:57] will have a incident response guideline [14:59] so that we can take action. [15:02] >> Yeah, sure. [15:08] Okay. So yeah, good question. So [15:10] basically [15:11] most of the hacks goes through private [15:13] block builders. So it's but if any go [15:16] with the public mem pool, what we can [15:18] do? We can have the transaction from the [15:21] mem pool. We can simulate it and on the [15:23] basis of the results, if it's harming [15:25] the protocol, if it's causing some [15:27] damage, we can front end that [15:28] transaction. [15:39] Okay. [15:40] All right. So this is not for the whole [15:42] Ethereum chain. That depends on protocol [15:44] to protocol. So if any protocol wants to [15:47] opt in for the monitoring thing, so we [15:49] can have data of there and we have a log [15:51] retention policy. We can apply for 30 [15:53] days, 60 days, 90 days based on the [15:54] requirement. [16:04] You no, that's I can we can use S3 [16:07] bucket out AWS. It's pretty cheap, [16:08] right? We'll be able to so what we can [16:10] do through remediate it, we can only [16:12] store 7 days of data in elk and after [16:14] that if the data is 7 days old, we can [16:17] directly store that in S3. S3 is [16:18] basically pretty cheap. So in order to [16:20] query the historical data, we can [16:21] directly go to the S3 and in order to [16:23] get the live data or anything, we can [16:25] just directly get it from there. [16:27] All right? Thank you. [16:29] Yeah. [16:33] Yeah. [16:35] It's Elk. [17:02] So basically Elk don't work. There is an [17:05] option in Elk. We can Basically, how Elk [17:07] store the data? They store data in [17:09] shards. So basically, when we store [17:11] data, there will be multiple shards of [17:13] the tables which we call index and that [17:15] gets stored at certain values. So in [17:18] Elk, we can also have multiple instance [17:20] of for example, Elk and multiple [17:23] database what we can say basically [17:26] multiple backup databases. [17:28] So what happened? For example, there are [17:30] four databases, one, two, three, four [17:31] and there are four Elk stances with [17:33] people are accessing, right? If one [17:34] database goes down, the other will be [17:37] able to give them the [17:39] data. [17:40] So basically we that depends on us. It's [17:42] very flexible. We can make multiple like [17:45] we can make it centralized, we can make [17:47] it decentralized. [17:52] Okay, I guess. Thank you. [17:54] >> Thanks so much.