DSS 2026 / Day 1 / Pearl Hall
Safe Staking: A Runtime Security Framework for LSTs
Yash Saraswat
Source: YouTube automatic caption track · Exported 2026-11-16. Timestamps link to the source video. Cue end times were not supplied.
Transcript
0:00Yeah, so my name is Yash and I work at a
0:02smart contract engineer at EtherFi. And
0:05today I want to talk about
0:07safe staking and in general, how do you
0:09protect a DeFi protocol
0:12like if you're if you're building a
0:13protocol yourself or if you're just like
0:15a regular user of a protocol, how do you
0:17know that
0:19any product that you use on chain is
0:21actually safe for you to use and safe
0:22for your funds. And
0:25yeah,
0:26I don't need to talk about this too
0:28much.
0:29This year has been quite quite a wild
0:33quite a wild in terms of smart contract
0:36hacks and DeFi hacks. And like mostly if
0:39you look at what has been happening this
0:41year, it's not exactly someone figuring
0:43out a way to hack a protocol like hack a
0:46smart contract or hack like some in
0:48where like
0:50logic in the code is mostly around
0:53access control. It's mostly around
0:55operational keys being leaked. It's
0:56mostly around like some pipeline going
0:58wrong and something like that.
1:00And
1:05and if you if you are a user and if
1:07you're using a DeFi protocol then you
1:09want to like be more confident that is
1:12the protocol I'm using actually safe or
1:13not. What are how how can you actually
1:16do that? So these are like three
1:18questions that you can probably ask
1:20yourself before putting your money in
1:21any protocol. And question one is who
1:23can move my funds?
1:25Question two
1:26[cough]
1:28what stops a bug from draining what
1:29stops a bug from draining them? And
1:31three, what happens when something
1:33breaks anyway? Like
1:35how does the incident response of a team
1:37look like etc.
1:40And
1:41the approach that I want to talk about,
1:42this is something that we applied
1:43EtherFi and I think it's a really good
1:45security model is the Swiss Swiss cheese
1:48model, which is like very simple. It
1:50basically means that at every single
1:52layer there are probably some things
1:56Excuse me. Sorry for my my coughing.
1:58There are probably a bunch of
2:01that can go wrong and these are the
2:02security holes through which attackers
2:04can find gaps and try to
2:07access access your funds. But if you
2:09stack a bunch of these layers on top of
2:11each other, then the chances that a
2:13hacker is able to find a gap through all
2:15of them and is able to
2:19break into break into everything and
2:20actually access your funds is quite
2:22less. And that is the whole point of the
2:25Swiss cheese model is that you just like
2:26add more and more security layers and
2:28more and more security features as much
2:30as you can think of and that just like
2:33exponentially reduces the amount of
2:36like surface that is available for a
2:38hacker to exploit.
2:43So the first
2:47so the first layer that I want to talk
2:48about is operational security.
2:50This is everything around admin keys,
2:53control matrix, pausing ability, etc.
2:57One thing that I forgot to add in the
2:58slides here, which is like very
2:59important is control matrix and
3:03the fact that like a protocol should
3:05[snorts]
3:05have a very clear and defined
3:08differentiation on like what type of
3:10access controls can move what type of
3:13levers. For example, let's say that
3:15there's a smart contract, there are some
3:16funds on it and there are some liquidity
3:18operations that you want to run and you
3:20can very clearly define on the smart
3:22contract that funds can only move in a
3:23certain way
3:25and you just need like
3:27an operational key to like do that based
3:29on your discretion. There is there is no
3:31chance of loss of funds if your smart
3:33contracts are audited and verified
3:36that the flow is not broken.
3:38In that
3:39[cough and clears throat]
3:42In that case, you can
3:44you can just like
3:45give an operational key access to move
3:47those funds and
3:51operational key access to move those
3:53funds and you can feel that okay, like
3:55this is like
3:58like good enough because like there is
3:59no potential loss of funds in that
4:00scenario. On the on the completely other
4:02extreme, let's say that
4:04you need to give access control now to
4:05upgrading your protocol contracts. That
4:08involves huge risk. Anyone who who can
4:10get access to controlling your protocol
4:13upgrades can like change the logic
4:16and like basically steal funds.
4:19Even thinking about like lower access
4:21controls like who can set some config
4:24parameters may cause a catastrophic
4:28catastrophic
4:29attack vectors for your protocol. So
4:31these these type of
4:34levers need a much more secure access
4:37control and that's and that's where time
4:40locks and multisigs and high threshold
4:43and high threshold controls are actually
4:45like quite useful. So it's always a good
4:47practice if you're working with any
4:49protocol to like check how their access
4:50control looks like.
4:52Do they actually have a policy where
4:54super critical functions like upgrades
4:56and config changes are actually behind
4:58secure
4:59secure thresholds because
5:02what we've seen over the last years a
5:03bunch of
5:06a bunch of hacks have happened because
5:07like someone just like
5:09blindly signed some transaction even
5:10it's even if it's behind a multisig it's
5:14it's not behind a time lock so you
5:16didn't get a chance to actually wait and
5:18see
5:20like what's going to happen on chain.
5:24The next lever is like on smart
5:25contracts. Obviously like if you're
5:27trusting a smart contract to have
5:29logic that protects you that protects
5:31you then you definitely need invariance
5:33as mentioned in the previous talk as
5:34well. And
5:37this is a this is a like
5:39quite
5:40like quite the norm in the industry that
5:42you definitely need like in invariance
5:44enforced in your smart contracts. You
5:45need to get them audited. If possible
5:47you should also get them formally
5:48verified. You should always have your
5:50invariance first tested, integration
5:52tested and
5:54and like run a bunch of static analyzers
5:57on it and
5:58[cough and clears throat]
5:59and yeah this is like pretty standard.
6:02The the next is also
6:05cross chain risk and actually want to
6:07like expand this also like to third
6:09party risk as well. Like you might have
6:11a protocol sitting
6:13on Ethereum mainnet and let's say like
6:16there are some cross chain let's say you
6:18have a token that is like deployed on
6:19some other chains, but
6:22basically what I mean by this section is
6:24that you also need to account for all
6:25the third party risk. Let's say you have
6:27external protocols integrated, you have
6:29a cross chain
6:31protocol integrated,
6:33then do you actually have the best
6:35possible config set
6:37for the security of those external
6:39layers? For example,
6:41we all know earlier this year
6:43our seeds got hacked because they were
6:45using layer zero infrastructure and they
6:47were
6:47not using the correct config. So instead
6:49of using their
6:52their recommended config, they were
6:53using a one of one demon which allowed
6:55them to get hacked. So
6:58can you ensure
7:01[laughter and cough]
7:03so can you ensure that before using any
7:04protocol are you actually use
7:06those that protocol actually have
7:08correct config set for all the
7:11external external dependencies that they
7:13have like there is no key that there's
7:16no like single operational key that has
7:18like very high privileged taxes. There
7:20is no like verifiers are
7:23for a cross chain protocol specifically
7:24there are like multiple verifiers etc
7:26etc.
7:30And then yeah and then the final lever
7:32is around active defense. This is
7:34basically like what do you do in the
7:36case that an hack actually happens? How
7:39do you act? How how can you ensure that
7:41you can minimize the effect of a hack?
7:43And
7:44the number one step for that is
7:45obviously detection. You you should
7:47always have monitoring, you should
7:49always have
7:51and that is where defining invariance is
7:53also
7:54incredibly helpful because if you know
7:56what can possibly go wrong, you can also
7:58create monitors to basically see if
8:00something suspicious happens. Basically
8:02that's how you define what being
8:05suspicious on chain is.
8:08And if you
8:09and if you detect anything like that you
8:10can start your incident response and go
8:13go move on to the next steps.
8:15The the second step is containment and
8:17this is something that I feel has like
8:19the most value and that is because
8:23you need to have the ability to have
8:25granular control over what actions you
8:28can take in order to contain a hack. For
8:30example, a bunch of protocols have
8:32pausing ability but
8:34[clears throat]
8:37but that is not really helpful if the
8:39only thing we can do is like pause the
8:41entire protocol because if the only
8:43thing that you can do is pause the
8:44entire protocol that means that you
8:46would be hesitant in using that ability
8:49unless you're like really sure that
8:51something really bad is happening and
8:54that is something that you should not
8:56have. You should never have hesitancy in
8:57order
8:59hesitancy in a situation where you
9:00believe something wrong might happen. So
9:04that's why having granularity and
9:06basically like the smallest action
9:07possible is really helpful. If you know
9:10for example for example we at Etherfi we
9:12are a staking protocol we have a staking
9:14token called VETH and we have an
9:16integration with Lido to manage
9:20like we hold some of our assets in Lido.
9:22So for example recently when the
9:24consensus validators
9:27got hacked when when what we saw was
9:31just that Lido is having mass exits and
9:34we at that point of time did not know
9:36why that was happening. So we could
9:38since we have this granular control that
9:40we can pause like certain flows instead
9:42of pausing the entire protocol we just
9:43took that action and paused
9:46flows related to Lido so that if there
9:47is some exposure to Lido that we're not
9:49aware of right now we can
9:52contain ourselves [clears throat] from
9:53that and then
9:55and then after containing then we can
9:56investigate and find out what happened
9:58within a few hours we within a few hours
10:00we
10:01got the whole picture that there was
10:02some key compromise in some
10:04[clears throat]
10:06in some validators and that like there
10:07is no real issue to us and that's
10:11when we
10:12when we unblocked the flow and we
10:14basically like recovered
10:16recovered our protocol back to the
10:17original state. We were we did not
10:19hesitate in taking that decision because
10:21pausing does not mean that we are
10:22pausing our entire protocol.
10:24Deposits still work, withdrawals still
10:26work,
10:27bridging still work, rebasing still
10:28worked, everything worked. The only
10:30thing that we paused was
10:32our integration with Lido and that
10:38and that granularity basically allowed
10:40us to have
10:41allowed allowed us to take that action
10:43that quickly without having any
10:45hesitation.
10:47The way we have built our pausing system
10:49it's also it also auto lists
10:50automatically. So like if there's if
10:52you're pausing a very critical action it
10:54auto lists like within eight hours and
10:57less critical actions have longer longer
10:59periods. We also have a feature we also
11:02have the ability to blacklist an
11:03address. This is something that we also
11:05did like very recently with the Binance
11:07hack where again like the Binance hack
11:10happened we did not know why it happened
11:12but the first thing we knew is that okay
11:13we can trace on chain like what are all
11:16the addresses that hold the
11:18that hold the stolen funds and we just
11:21started blacklisting those addresses and
11:22that is also like one lever that we
11:24could take that which just
11:27it does not mean that that attacker
11:29could not have
11:33could not have like move funds to
11:35another address bypass our blacklist by
11:37like rotating address faster than we
11:39were able to take action and then enter
11:41our protocol but it's just like it's an
11:43extra layer of security. Like if we
11:44wanted to discourage the hacker from
11:46using our protocol to like launder the
11:48funds he would not he would probably be
11:50discouraged because he could see that we
11:52are blacklisting his addresses. So
11:55so that's what I meant initially like
11:57more layers of security it's it it's not
12:00a guarantee that your system is secure
12:02but it also add it just adds like
12:06more probability that your security that
12:08your system is going to be safer.
12:13[cough]
12:15And coming back to invariants. So if
12:17you've defined an invariant, that means
12:18that if that invariant has gone wrong,
12:20then like you are
12:23then that's pretty bad basically.
12:26In that scenario, if you have like
12:28defined like what going wrong actually
12:30instead of defining just like what a
12:32suspicious activity looks like, you can
12:34actually
12:36you can actually wire wire
12:39wire that monitor to directly
12:41take actions without any human without
12:43any human intervention. And that is what
12:45I mean by atomic pause. But you cannot
12:48just wire that willy-nilly and you
12:50cannot just
12:53you cannot just like wire any monitor to
12:54an auto pause because like if that
12:56monitor falsely fires for any reason,
12:58then you probably have like
13:01caused caused your protocol to
13:06caused your protocol to like have some
13:07downtime that it did not deserve. So we
13:10also have like a policy on like what it
13:11means for a what it means for a monitor
13:14to be promoted to
13:16actually firing an auto pause. And that
13:18is a number one policy is that the
13:20monitor should actually be
13:21deterministic. It should not be
13:23like monitoring something that oh it's
13:25over a threshold. That means it's
13:26suspicious. We should investigate. No,
13:28it's a deterministic thing like we have
13:29an exchange rate for V and the
13:31underlying TVL. And if that exchange
13:33rate is broken, then that means that
13:35yeah okay something bad has happened. We
13:36should pause the protocol and start
13:38investigation immediately. We have a
13:39verified coverage of it. Like whatever
13:41we are
13:43whatever we're trying to monitor, we can
13:44actually deterministically verify
13:47the sources
13:50the sources of like where the monitor is
13:52being fed from.
13:54We test it and see that there are
13:55actually zero false positives over over
13:58used in a back tested window. And then
14:00finally
14:02the arm is also
14:03the arm is also like our goal is to set
14:06set it to the smallest possible action
14:09that can be taken
14:11up and that invariant goes wrong so that
14:13we can also minimize the plus radius
14:15in case there is a false positive.
14:19And yeah, the same layers that I have
14:20been talking about also apply to all our
14:23other products for our
14:25for our cash product, for a liquid
14:26vaults and also for the RV market that
14:29we have. So we basically follow these
14:31policies across
14:35all our all our products and that's how
14:38we like ensure that we provide the
14:40safest product to the users. So if you
14:42are a user and you want to put your
14:44money in any protocol,
14:47you should probably
14:49probably answering these questions and
14:50trying to find the answer of these
14:51questions would give you a very good
14:54understanding of like
14:56how the secure, how seriously that
14:58protocol takes this takes its security.
15:01And yeah, hopefully that will allow you
15:04to make
15:05better decisions with keep your
15:08money.
15:09And yes, same thing.
15:12So yeah, thank you.
15:14>> [applause]
Source and accuracy details
- Names, organizations, technical terms, code and numbers may be misrecognized.
- Source wording and disfluencies are preserved; no editorial corrections were applied.
- Export contains whole-second cue starts only; cue ends and subsecond timing are unavailable.
- A full caption-track export does not establish that every spoken word is represented.
- Automatic YouTube captions; not human-verified against the audio.
Source export SHA256: f1ed1a5ce2ab458c1d7d5dbfb9780bb5de644243f78fd590f756a51eb1cbd9e0