WEBVTT

00:00.000 --> 00:01.900
I'm going to announce Chris McCoy.

00:01.900 --> 00:03.300
He's a good friend of mine.

00:03.320 --> 00:05.500
He's been at Cisco for 12 years.

00:05.580 --> 00:10.100
He's in this super spooky group called ASIC, like he mentioned.

00:10.100 --> 00:12.820
Nobody knows much about that village.

00:13.700 --> 00:17.360
I mean, much about that portion of Cisco.

00:17.360 --> 00:20.340
He's going to explain quite a bit about what they do.

00:20.480 --> 00:24.680
And then also open up some other information that I think you'll enjoy.

00:25.220 --> 00:27.660
He's a... well, you can see.

00:27.660 --> 00:29.500
He's a principal engineer for Cisco.

00:29.500 --> 00:31.820
He actually is going to be next door.

00:31.820 --> 00:35.060
He's been helping with setting up and running the village with us.

00:35.060 --> 00:38.020
So give a warm welcome to Chris McCoy.

00:38.020 --> 00:38.840
Thank you.

00:39.720 --> 00:41.100
Thank you, Joseph.

00:41.220 --> 00:41.860
Thank you.

00:43.000 --> 00:44.420
Thank you, Joseph.

00:44.720 --> 00:46.860
So yeah, my name is Chris McCoy.

00:46.920 --> 00:52.320
I am with ASIC, the Advanced Security Initiatives Group in Cisco.

00:52.720 --> 00:54.960
And we're primarily based out of Knoxville.

00:54.960 --> 00:56.180
We have people in Austin.

00:56.180 --> 00:59.220
We have people in RTP and all over, really all over the world.

00:59.220 --> 01:05.960
And what we do is we are the primary white hat hacker organization for Cisco.

01:05.960 --> 01:07.620
So let me go ahead and get into this.

01:07.620 --> 01:15.620
I'm actually going to show you a real security evaluation that we did on application-centric infrastructure and the results that we had.

01:16.100 --> 01:18.080
And anyway, let's just get into it.

01:18.580 --> 01:19.780
Hopefully you can see this.

01:19.780 --> 01:21.280
So these are the greats that fly.

01:21.280 --> 01:22.840
Nicholas, thank you so much.

01:22.840 --> 01:24.460
Everett, thank you so much.

01:24.460 --> 01:26.600
Amit, you know who you are.

01:26.600 --> 01:31.900
Omar and the rest of the ASIC crew, Terry, I couldn't have done this without you, so thank you.

01:31.900 --> 01:34.940
And audience, please save your questions until the end.

01:34.940 --> 01:37.980
I have a lot to get through, and I have a lot I want to show you.

01:38.120 --> 01:42.800
So just wait until the end, and then I'll answer any questions you have within reason.

01:42.960 --> 01:43.540
Okay?

01:46.180 --> 01:47.560
All right, so disclaimer.

01:47.560 --> 01:49.680
I am speaking for myself and not Cisco.

01:49.680 --> 01:53.140
I am not officially here on behalf of Cisco.

01:53.200 --> 01:54.640
I am in a Cisco group.

01:54.640 --> 01:56.840
This information is three years old.

01:56.960 --> 02:00.400
So these vulnerabilities that I am sharing with you have been around a long time.

02:00.400 --> 02:02.820
Just to give you an idea about when we got started.

02:02.820 --> 02:11.760
We got started on ACI just right after Cisco acquired NCME, which is the business unit that this came from.

02:12.180 --> 02:16.260
And so this is... a lot of this stuff has already been disclosed.

02:16.260 --> 02:18.820
It's already been released to customers a long time ago.

02:18.820 --> 02:23.000
And if this stuff still affects your network customers, it's because you aren't patching.

02:23.000 --> 02:24.180
Please patch.

02:24.680 --> 02:25.080
Okay.

02:25.280 --> 02:28.360
And this is not a rebuttal to the Black Hat 2019 talk.

02:28.360 --> 02:32.840
There was a talk called Apex Adventure in ACI Wonderland by Oliver and Frank Block.

02:33.640 --> 02:36.500
The findings might be interesting to those that have seen that.

02:36.500 --> 02:40.380
But if you haven't seen that before, it looks like I need to stay away from that speaker.

02:41.180 --> 02:44.940
But the findings may be interesting if you've seen that talk.

02:44.940 --> 02:47.660
But if you haven't seen that talk, then I'll actually go through this whole thing.

02:48.240 --> 02:52.640
Security and Trust Organization is who I'm part of with the Advanced Security Initiatives Group.

02:52.640 --> 02:54.360
And so we're security-focused.

02:54.360 --> 03:01.140
We try to find security vulnerabilities as early as possible in the product lifecycle.

03:01.140 --> 03:06.280
So we have... usually we work in about three or four team members.

03:06.280 --> 03:08.180
And we just hammer on a product.

03:08.180 --> 03:08.980
It could be for a month.

03:08.980 --> 03:10.400
It could be for six months.

03:10.400 --> 03:16.500
It's basically like a red team that lasts a long, long time looking for vulnerabilities.

03:16.500 --> 03:20.540
And we discover those zero days and we get them patched out and get our customers protected.

03:20.540 --> 03:21.500
That's what we're here for.

03:23.300 --> 03:26.440
I also wanted to tell you that networks are not that boring.

03:26.440 --> 03:29.960
I've made an entire career out of hacking networks.

03:30.220 --> 03:31.300
It's amazing.

03:31.640 --> 03:36.580
There are so many things and so many opportunities for red teaming networks you have no idea.

03:37.140 --> 03:39.740
Apps and operating systems I actually find a little bit boring.

03:39.740 --> 03:40.900
I like the plumbing.

03:41.140 --> 03:47.640
Because the plumbing has a lot of opportunities for attack surfaces and all kinds of things.

03:47.640 --> 03:48.860
And I'm going to show you one.

03:49.620 --> 03:53.080
Okay, so I'm going to get into software-defined networking, SDN.

03:53.240 --> 03:55.240
SDN means a lot of things to a lot of people.

03:55.240 --> 03:56.880
It has a bunch of different definitions.

03:57.180 --> 03:59.680
This is really what it is, kind of boiling it down.

04:03.460 --> 04:07.580
So, boiling down software-defined networking, it is really about a central point of management.

04:07.580 --> 04:08.640
That's what you want.

04:08.660 --> 04:12.940
You want to optimize your network for physical, virtual machines and containers.

04:13.260 --> 04:19.040
You also want to do some kind of policy enforcement so that you have what are called micro-segmentation.

04:19.040 --> 04:22.340
Where only certain services can talk to other services.

04:22.340 --> 04:24.000
And I'll get into that a little bit more.

04:24.380 --> 04:27.180
But really what you need is you need programmability.

04:27.180 --> 04:30.360
You need to adapt the network to the endpoints, the agile forwarding path.

04:30.360 --> 04:32.040
And you need to have some kind of discovery.

04:32.040 --> 04:34.180
You need to know where things are located.

04:34.500 --> 04:38.320
In ACI, in Cisco ACI, this is made for a data center.

04:38.420 --> 04:41.860
It is designed to scale up to one million endpoints.

04:41.900 --> 04:45.480
And an endpoint can be a VM, it's an IP address, MAC address.

04:45.480 --> 04:49.860
It scales up to that large of a data center.

04:50.200 --> 04:54.100
It also has the property of multi-tenancy.

04:54.380 --> 04:58.860
So you have many different customers that are all connecting to the same data center network.

04:58.860 --> 05:01.000
And they all want to be able to control their own policies.

05:01.000 --> 05:02.800
So it's a multi-tenant environment.

05:03.100 --> 05:06.320
You also want to control how endpoints communicate.

05:06.320 --> 05:10.940
What TCP ports are available from one source to a destination.

05:11.440 --> 05:13.700
You also want to be able to insert middle boxes.

05:13.700 --> 05:18.780
You want to do things like load balancing, real firewalls, NAT.

05:18.780 --> 05:21.640
If you're doing carrier-grade NAT, maybe you need something like that.

05:21.680 --> 05:27.260
And so the answer to all of this is the application-centric infrastructure or ACI, Cisco's ACI.

05:27.660 --> 05:29.460
And so this is the way the fabric looks.

05:29.460 --> 05:34.900
The fabric is made up of switches that are in the rolls of leafs and spines.

05:35.000 --> 05:39.680
So this is what's called a cloth network, if you've ever heard of this, a bipartite graph.

05:39.680 --> 05:46.660
You have a spine, and the spines are really responsible for routing traffic from one leaf to the other.

05:46.660 --> 05:51.280
The leafs are fully meshed up to the spines, and the spines are fully meshed down to the leafs.

05:51.320 --> 05:54.480
And the idea is that you can load balance across the spines.

05:54.760 --> 05:56.300
And this is just one layer.

05:56.300 --> 06:01.000
You have very large networks, like at Facebook, where they have multiple layers of leaf and spines.

06:01.800 --> 06:05.200
They also have other layers down here, too, where you have maybe top-of-rack switches.

06:05.200 --> 06:06.960
But typically, this is what it looks like.

06:06.960 --> 06:10.740
And then attached to the leafs, you have the controllers.

06:10.740 --> 06:12.260
Those are called your APICs.

06:12.260 --> 06:17.320
That's your Advanced Policy Infrastructure Controller, is what an APIC stands for, APIC.

06:18.560 --> 06:21.080
And attached to your leafs, you've got your servers.

06:21.080 --> 06:22.580
You've also got something called VLEAFS.

06:22.580 --> 06:30.320
This is your hypervisors that actually are running the code, the ACI code, to be able to do the fine-grained policy that I was talking about earlier.

06:30.360 --> 06:33.180
You have virtual machines and containers that are running in there.

06:33.180 --> 06:34.920
You've got your firewalls.

06:34.920 --> 06:39.100
These are your services, your Layer 4 through 7 services that you're doing for load balancing.

06:39.320 --> 06:41.220
And then you have external networks of some kind.

06:41.220 --> 06:43.140
You have to connect this somewhere.

06:43.480 --> 06:48.020
You have to connect to routers and switches that go outside.

06:48.020 --> 06:50.020
You need to sometimes maybe connect to the Internet.

06:50.020 --> 06:51.980
You need to connect to your intranet.

06:51.980 --> 06:53.420
And you'll have an external network.

06:53.420 --> 06:57.300
And so the thing to keep in mind is, for the most part, you don't attach to the spines.

06:57.300 --> 06:58.940
That's not always true.

06:58.940 --> 07:04.620
But you attach to the leaf, and you'll have things like services for leafs that you attach to.

07:04.860 --> 07:06.080
Is everybody with me so far?

07:06.080 --> 07:08.200
This is an example of what these switches look like.

07:08.200 --> 07:10.200
They are rather high-powered.

07:10.480 --> 07:15.520
The ones on the top actually do power over Ethernet, so you can attach things like phones and cameras to them.

07:15.780 --> 07:23.840
The one on the bottom, that has multiple 25 gigabit Ethernet connections, and it has, I believe, it's either 100 gig...

07:23.840 --> 07:26.400
Yeah, I think it's 100 gig uplinks that it has.

07:26.400 --> 07:28.400
So this is pretty high-powered stuff.

07:28.400 --> 07:32.180
Many, many different connections, like I was talking about earlier, up to a million endpoints.

07:33.160 --> 07:34.400
Okay, ACI, they have...

07:35.240 --> 07:36.480
So I'm a CCIE.

07:36.480 --> 07:38.860
I've been doing networking for about 25 years.

07:38.920 --> 07:45.440
And I had to completely unlearn networking to really understand how this thing worked, because it was just boggling the heck out of my mind.

07:45.440 --> 07:46.720
I just couldn't understand it.

07:46.740 --> 07:50.520
But at first, really, I had to unlearn it and then relearn it to really understand what's going on.

07:50.580 --> 07:53.100
When you have VLANs, they aren't really VLANs per se.

07:53.100 --> 07:54.480
I mean, they're not bridge domains.

07:54.480 --> 07:59.180
They represent what are called endpoint groups, EPGs, endpoint groups.

07:59.180 --> 08:04.260
And endpoint groups are a grouping of endpoints, and they are allowed to freely communicate inside of the endpoint group.

08:04.260 --> 08:10.580
So all of your endpoints that are inside of your endpoint group, they can talk to each other without any kind of policy, any kind of constraints.

08:10.720 --> 08:14.160
You can go from one endpoint group to the other without any problems.

08:14.200 --> 08:19.040
So the idea with this is that, you know, we're running out of IPv4 addresses, right?

08:19.040 --> 08:25.040
I mean, and people have to make these very large networks, and you have to be able to constrain your network so that...

08:25.720 --> 08:31.100
or you need to be able to design your network so that you don't have to be constrained by IP addresses and VLANs and all those things.

08:31.100 --> 08:33.040
And that's what EPGs are all about.

08:33.620 --> 08:34.100
Contracts.

08:34.140 --> 08:38.020
Contracts are what allow you to talk from one EPG to another.

08:38.020 --> 08:47.210
These are basically saying you have a provider and consumer relationship that says, I am providing TCP 443, HTTPS.

08:47.210 --> 08:49.830
I'm providing this to anybody that wants it.

08:49.910 --> 08:57.150
And then if I have a contract that comes along and it consumes that endpoint group, then that endpoint group can use that TCP 443.

08:57.250 --> 09:01.430
And if you're not part of that contract, then you don't get access to that port.

09:01.430 --> 09:02.910
It's the way it's supposed to work.

09:03.850 --> 09:07.490
Okay, inside of the fabric, the fabric is completely Layer 3.

09:07.490 --> 09:13.550
Even when you're doing Layer 2 connectivity, when I say Layer 3 and Layer 2, when I say Layer 3, you're actually going through a router.

09:14.390 --> 09:19.450
When you're going through from one endpoint group to another endpoint group, you're always going to be routing.

09:19.710 --> 09:22.070
And the way they do this is they use an overlay.

09:22.070 --> 09:24.770
You've probably heard of things like VXLAN.

09:24.810 --> 09:30.970
If you haven't learned VXLAN, you don't understand VXLAN, you really should, because everything is going that way.

09:30.970 --> 09:37.130
And they're starting to even use VXLAN in the edge of your network in your access layer.

09:37.130 --> 09:41.630
Cisco has software to find access, and I'm sure there's probably a lot of other ways out there.

09:41.710 --> 09:44.930
But as it turns out, it makes it really easy to be able to do policies.

09:44.930 --> 09:47.410
Please save your questions until the end of the presentation.

09:47.410 --> 09:48.190
Thank you.

09:49.150 --> 09:51.270
Okay, your links are IP unnumbered.

09:51.270 --> 09:53.310
We're using ISIS internally.

09:53.310 --> 09:54.790
That's the routing protocol that they use.

09:54.790 --> 10:00.490
And one of the things about ISIS that makes it really interesting is that it runs on link, and it runs at Layer 2.

10:00.530 --> 10:05.610
And it doesn't actually give you an opportunity to be able to inject things across broadcast domains.

10:05.610 --> 10:13.270
So if you're on a switch, what this means, if you're on a switch, you're not able to actually get access to that link to be able to inject things into ISIS.

10:13.270 --> 10:14.410
So it's a little better.

10:14.710 --> 10:21.650
But it's always Layer 3 routed, and they advertise what are called VXLAN tunnel endpoint IP addresses.

10:21.850 --> 10:25.670
So whenever you have a frame to send, it goes into the leaf switch.

10:25.670 --> 10:31.510
The leaf switch encapsulates it in VXLAN and routes it across the fabric to the destination leaf switch.

10:31.510 --> 10:40.830
The destination leaf switch then takes that encapsulated Ethernet packet frame, strips off the VXLAN stuff, and sends it on its way to where it needs to go.

10:42.090 --> 10:44.210
And they use ISIS.

10:44.210 --> 10:46.130
It's been tuned for a densely connected fabric.

10:46.130 --> 10:50.850
So of course you have many connections that are going all over the place, and it's been tuned so that it works.

10:50.850 --> 10:52.090
And they use IK multicast.

10:52.090 --> 10:55.610
If you don't know where things are going, they use anycast.

10:55.830 --> 11:00.610
So one of the things I'll talk about a little bit later on is that the spines are not dumb.

11:00.610 --> 11:02.790
The spines are actually really smart.

11:02.790 --> 11:05.850
They're the ones that do all of the tracking of who's connected where.

11:07.370 --> 11:10.450
We talk about tenants, VRFs, and bridge domains.

11:10.630 --> 11:19.910
VRFs, and they call this a context inside of ACI, but it's basically when you get boiled down to it, you've got a VRF, which is a routing table.

11:19.910 --> 11:29.190
You have a bridge domain, and the bridge domain contains subnets, and those subnets can be anywhere on any leaf switch that's in your fabric.

11:29.190 --> 11:32.750
And you have multiple of these since you have multiple tenants.

11:34.250 --> 11:35.510
So endpoint discovery.

11:35.510 --> 11:42.930
So when a device talks to the fabric for the first time, it will maybe send DHCP, send ARP, send something.

11:42.930 --> 11:45.470
It doesn't know who it is and who it's talking to.

11:45.470 --> 11:50.750
So what happens is the leaf switches are constantly listening on these things to do discovery.

11:50.750 --> 11:59.950
So when a VM, for instance, sends a packet for the first time, the leaf switch will pick it up, and it does a source lookup to see whether or not it knows where that leaf or that source is.

12:00.110 --> 12:04.090
And once the endpoint is discovered, it sends through a proprietary protocol called COOP.

12:04.090 --> 12:09.690
That's the Council of Oracle's protocol, and that's how it does location learning.

12:10.370 --> 12:17.830
So just in this example here, I'm showing something different where we have a VM that's running in vSphere.

12:17.830 --> 12:19.630
It's running VMware.

12:19.770 --> 12:21.030
It talks to the vSwitch.

12:21.030 --> 12:24.890
The vSwitch then sends it on to the vXLAN endpoint.

12:24.890 --> 12:27.530
So this is supposed to be agnostic.

12:27.530 --> 12:29.210
Pretty much vXLAN has won out.

12:29.210 --> 12:32.310
There's another encapsulation technology out there called Geneva.

12:33.170 --> 12:39.230
But there used to be NVGRE, and I think Microsoft has also kind of moved away from that.

12:39.250 --> 12:56.890
But once the ingress learns the MAC address and IP address of the arriving frame, it sends that along with the ingress port vLAN and vXLAN to the switch, and then the leaf forwards that endpoint address to the spines using the 0MQ protocol.

12:56.890 --> 12:58.050
That's what they use.

12:58.510 --> 13:03.350
And then that information is spread out, or it's distributed to all of the spines.

13:03.350 --> 13:06.970
So all of the spines know at any one time who's connected where.

13:06.970 --> 13:08.430
Hopefully that makes sense.

13:08.730 --> 13:10.590
This will come important later.

13:10.590 --> 13:23.170
And then when you send the information, when you send the frame to the egress leaf, the egress leaf then is able to learn the source address, MAC address, and all that other information when it gets to where it's going, unless you tell it not to.

13:23.170 --> 13:25.590
There's a flag in the frame that says don't learn this.

13:26.810 --> 13:27.950
So what is this for?

13:27.950 --> 13:29.250
What are we going with this?

13:29.250 --> 13:31.170
So just showing you, this is the life of the packet.

13:31.170 --> 13:32.270
This is how the packet works.

13:32.270 --> 13:35.030
It's sent from the vSwitch to the vTEP.

13:35.030 --> 13:43.950
The leaf switch then, if you're using vXLAN, it actually swaps out the vXLAN information for its own internal and semi-vXLAN protocol.

13:43.950 --> 13:46.850
It goes across the fabric.

13:47.230 --> 13:53.070
If it doesn't know the destination, it sends it to a spine using an anycast IP address.

13:53.070 --> 14:00.910
And it's just basically a range of IP addresses that are allocated to all of the spines, and all the spines are listening on that IP address all the time.

14:00.910 --> 14:05.390
Then in hardware, they're able to do that lookup to find out where that actual destination is.

14:05.390 --> 14:07.790
And then it gets sent to the destination leaf switch.

14:07.790 --> 14:10.770
The leaf switch then strips off that information and replaces it.

14:10.770 --> 14:14.510
If they're using VLANs for your endpoint groups, it can use VLANs.

14:14.510 --> 14:18.330
If you're using NVGRE, which isn't as popular anymore, they may use that.

14:18.750 --> 14:20.650
But that's basically how it all works.

14:22.690 --> 14:24.610
So then we get into VRFs.

14:24.610 --> 14:26.410
I'm going to just zip through this a little bit.

14:26.630 --> 14:32.850
But this just shows how tenants, VRFs, and bridge domains, and endpoint groups all work together.

14:32.850 --> 14:35.770
How the frame source information is kept.

14:35.770 --> 14:39.690
It's actually relayed from one leaf switch to the other through vXLAN.

14:39.690 --> 14:44.770
And the APIC controls the allocation of VNID labels across the fabric.

14:44.810 --> 14:53.010
By labels, I mean things like your actual VNIDS, that's your vXLAN network ID, and your source groups, and all those other things.

14:53.010 --> 14:57.330
And it does policy enforcement either at the source or the destination.

14:57.970 --> 15:04.110
And whether or not the policy has already been enforced is signaled through a flag in the label.

15:04.110 --> 15:05.870
And this will become important later.

15:06.890 --> 15:12.470
Central Management and ACI, they use a REST API that's load-shared through the APICs for everything.

15:12.470 --> 15:15.970
In other words, you can put a load balancer in front of this thing and it would work just fine.

15:15.970 --> 15:18.390
It doesn't matter which APIC it shows up on.

15:18.770 --> 15:23.210
It uses what's called sharding, which sounds really dirty to me.

15:26.030 --> 15:28.490
But everything is sharded.

15:30.010 --> 15:34.170
In other words, they have different instances that run on different APICs.

15:34.170 --> 15:36.910
I'm going to get into the security a little later on, I promise you.

15:37.710 --> 15:39.790
But they use this API for everything.

15:39.790 --> 15:43.550
They use it for the REST, they use it for the GUI, they even use it for the CLI.

15:43.710 --> 15:51.470
So when you're on the command line interface and you're SSH'd in, they actually run a chroot jail when you're SSH'd into the box.

15:52.110 --> 15:58.750
And even when you're talking to, even when you're configuring things through the CLI, that even gets translated up to the REST API.

15:58.750 --> 16:02.050
So they really have only one way in or out of this system.

16:02.050 --> 16:05.290
Which is good, because it only gives you one thing to secure.

16:06.530 --> 16:10.890
And they also have a Python SDK called Cobra that they use to manage.

16:10.890 --> 16:13.070
So let's actually get into the interior of this thing.

16:13.070 --> 16:14.850
This is how it all fits together.

16:14.930 --> 16:16.310
These are your switches.

16:16.310 --> 16:19.690
These could be either leafs, these could be spines, and then you have your APICs.

16:19.730 --> 16:25.790
And your APICs somehow magically can connect to and talk to the leaf switches or the spines.

16:25.790 --> 16:28.050
And the APICs run these processes inside them.

16:28.050 --> 16:30.910
These are called data management engines, or DMEs.

16:30.910 --> 16:36.130
And the DMEs have their own internal proprietary protocol called intrafabric messaging.

16:36.390 --> 16:40.190
And the primary front door through this whole thing is through NGINX.

16:40.750 --> 16:47.750
So the DMEs are responsible for a little part of something called the Management Information Tree, or MIT.

16:48.310 --> 16:51.770
And all communication happens through NGINX.

16:51.770 --> 16:54.590
So if you're going from the outside in, you're going through NGINX.

16:54.730 --> 17:00.430
And they communicate to each other from the switch, from the APICs, all through IFM.

17:00.430 --> 17:06.090
And it happens in between the VTAP IP addresses, and how they secure that I'll get into in a little bit.

17:07.030 --> 17:10.310
This is just a gee whiz diagram of how this all works.

17:10.310 --> 17:16.170
What's important here is that they have the intrafabric messaging that comes in over TCPIP.

17:16.170 --> 17:19.230
So internally, this is all proprietary the way this all works.

17:19.730 --> 17:21.730
They have the doer.

17:21.730 --> 17:26.270
They have this model that tells what they need to do in this Management Information Tree.

17:26.270 --> 17:29.930
And they have a replicator to replicate it to other DMEs if you're doing sharding.

17:29.930 --> 17:33.430
And then they have a persistifier which stores to an SQLite database.

17:33.610 --> 17:36.310
And each of these has its own database.

17:36.370 --> 17:41.310
And they also structured it so that if for sensitive data, they encrypt that data.

17:41.310 --> 17:44.610
If it needs to be encrypted, it will be encrypted on the box.

17:45.690 --> 17:47.130
It's actually not a bad design.

17:47.130 --> 17:49.170
I'm pretty impressed with it otherwise.

17:49.330 --> 17:55.230
Communication of policy and ACI, they use DME to DME communication through IFM.

17:55.270 --> 17:58.690
And they use TLS using mutual authentication.

17:58.690 --> 18:02.770
So there is authentication not only of the client but also of the server.

18:02.770 --> 18:07.030
And the certificates that they use are loaded on the switches in the APICs at the factory.

18:08.190 --> 18:13.510
So the certificates that are used, they have a very long expiration date.

18:13.750 --> 18:20.890
And the way they work is they use that certificate to authenticate the client and authenticate the server.

18:21.710 --> 18:24.030
I think you guys can see where this is going.

18:24.710 --> 18:34.530
The abstract policy on the APIC that they use, the endpoint groups, they actually take that and they make it concrete and they enforce it in the leaf switches using the DMEs.

18:35.570 --> 18:45.690
So for device discovery and ACI, if you were to plug an APIC into anything, the only protocol that it speaks at first is LLDP.

18:45.690 --> 18:47.750
That's Link Layer Discovery Protocol.

18:47.810 --> 18:52.770
If you were to plug into a switch, the only protocol that they use is LLDP.

18:52.770 --> 18:54.350
That's all we saw.

18:54.350 --> 18:57.270
So I was like, oh great, what's the attack surface going to be?

18:57.390 --> 18:58.350
Obviously , the LLDP.

18:58.350 --> 19:01.030
That's one of the main things that we're going to be using.

19:01.390 --> 19:11.910
One of the things that I'm really kicking myself in the butt for is that the folks that I was telling you about earlier that did the Black Hat talk, they found a buffer overflow in LLDP that we missed.

19:12.150 --> 19:16.830
And I feel really bad about it and I wish we had found it earlier, but hey, it's patched.

19:16.850 --> 19:22.310
And if you're listening to this video, please patch your fabric.

19:23.630 --> 19:32.270
Custom TLV, they have their own little proprietary TLV that they use for discovering the fabric so the fabric can discover the APICs.

19:32.570 --> 19:40.130
And when the switches see these custom TLV packets, they will open the underlay to the device that's connected to it.

19:40.130 --> 19:44.830
And one of the things about LLDP which makes it interesting is it doesn't travel over switches.

19:44.930 --> 19:48.510
It only travels inside of a broadcast domain, actually a collision domain.

19:48.510 --> 19:50.590
It's only from one point to the other point.

19:50.590 --> 19:55.510
There are multiple MAC addresses, but one of the MAC addresses that they actually use here will only travel one hop.

19:55.510 --> 19:57.190
It won't go any further than that.

19:57.530 --> 20:05.250
And what that also means is that unless you really screwed up with your hypervisor configuration, you have to be bare metal attached to be able to tinker with this.

20:05.250 --> 20:06.830
You can't do it from a VM.

20:07.310 --> 20:08.210
Make sense?

20:10.390 --> 20:12.330
So here's the real deal.

20:12.330 --> 20:13.530
Here's what we did.

20:13.530 --> 20:15.070
I've given you all the background.

20:15.070 --> 20:18.850
You know about DMEs, you know about LLDP and all those wonderful things.

20:18.850 --> 20:19.970
How are we going to do this?

20:19.970 --> 20:21.450
How are we going to actually own a datacenter?

20:21.450 --> 20:22.430
Here's what we're doing.

20:22.970 --> 20:24.670
Sure, let's own the datacenter.

20:24.670 --> 20:29.610
So in this case, in this situation, you have a device that maybe got owned.

20:29.610 --> 20:31.590
It's a bare metal device.

20:31.590 --> 20:33.010
Let's say it's not a hypervisor.

20:33.010 --> 20:38.130
Or maybe it could even be a hypervisor where somebody escalated privileges and got access to the hypervisor.

20:38.130 --> 20:46.110
Or maybe they were in a container and they escalated privileges and got access to the hypervisor so that they can send directly to that leaf switch and be able to talk LLDP.

20:47.490 --> 20:49.650
So that's the situation here.

20:49.650 --> 20:53.850
And what we want to do is we want to attack the APIC, which is more than one hop away.

20:53.850 --> 20:58.670
And remember, this is a Layer 3 switch fabric and it has overlays.

20:58.670 --> 21:02.710
And normally we can't even talk to the APIC because the APIC does not process packets.

21:02.810 --> 21:05.790
The packets flow from leaf to spine to leaf.

21:05.810 --> 21:06.850
They don't go through the APIC.

21:06.850 --> 21:09.330
We don't even have a way of talking to the APIC or touching the APIC.

21:09.330 --> 21:12.550
So we need something to be able to get us access to that.

21:12.550 --> 21:16.470
It's the central point of management for the entire ACI fabric.

21:16.910 --> 21:20.890
Anything that an admin can do, they can do from there and it makes it for a very tempting target.

21:20.890 --> 21:22.230
It's a sync target.

21:22.230 --> 21:24.210
It's the controller in your entire network.

21:24.370 --> 21:27.770
If you have a million endpoints, they're all being controlled from the APIC.

21:28.650 --> 21:33.270
So central management, we looked at the GUI and the GUI actually looks pretty good.

21:33.270 --> 21:36.090
They use an off-the-shelf framework.

21:36.090 --> 21:37.790
I forget which one it is right now.

21:37.790 --> 21:40.550
They probably have already changed it anyway because this is from...

21:40.550 --> 21:47.130
When we did this eval, it was on 1.1 or 1.2 was the version and I think they're up to 4 something now.

21:47.130 --> 21:49.030
So they've been around a long time.

21:49.170 --> 21:51.950
So they had cross-site request forgery protections.

21:51.950 --> 21:53.550
That's one of the first things we'll look for.

21:53.630 --> 21:58.050
They were very well protected from XSS but not for the reasons you would think.

21:58.710 --> 22:07.810
Anytime they took any kind of data from the user for any field, they would limit all of the fields to basically alphanumeric characters, spaces and things like that.

22:07.810 --> 22:08.630
And that's all you could do.

22:08.630 --> 22:10.590
You could never do anything like brackets.

22:11.550 --> 22:16.950
So we thought, well how can we do this by looking for some fields that may not be user input?

22:17.290 --> 22:22.030
And so we did XSS, actually cross-channel scripting on LLDP.

22:22.430 --> 22:26.230
So the idea is that you may do a social engineering attack.

22:26.510 --> 22:29.190
And you say, hey admin, I'm having a problem.

22:29.190 --> 22:30.090
I'm not getting connected.

22:30.090 --> 22:31.630
Can you make sure that I'm connected to something?

22:31.630 --> 22:36.830
Can you go look at my interface and look at LLDP for me and see what you see?

22:36.830 --> 22:42.470
Because I'm sending out LLDP and if you say that it's really attached to my machine, I'd really like to know.

22:42.470 --> 22:44.350
And so you get somebody to look at it.

22:44.350 --> 22:48.210
In the meantime, notice on the right hand side we have local users.

22:48.210 --> 22:52.190
We're going to run this script that just sends an LLDP frame, single frame.

22:52.190 --> 22:52.490
Boom.

22:52.490 --> 22:53.470
Did you see it?

22:54.890 --> 23:00.930
Just by taking advantage of the access that the browser had, we're able to create our own user.

23:00.930 --> 23:02.550
There's a user now called Hacker.

23:02.550 --> 23:04.190
And we'll just have this open at the same time.

23:04.190 --> 23:05.730
That happened in real time.

23:06.410 --> 23:11.950
So now if you look, we have access to pretty much everything on the APIC.

23:11.950 --> 23:13.030
Well, that's fun.

23:13.350 --> 23:14.990
So let's go a little bit further.

23:15.850 --> 23:17.090
We need a route.

23:17.090 --> 23:18.670
We need some way of getting to the APIC.

23:18.670 --> 23:21.810
Let's say the APIC's behind a firewall, which hopefully they are.

23:22.030 --> 23:26.430
We have no real way of getting to them, but we do have access to the fabric.

23:26.590 --> 23:28.590
So let's see if we can get access to that.

23:28.990 --> 23:32.050
So there is something called the infrastructure VLAN.

23:32.050 --> 23:38.610
If you've used ACI before, there's this little checkbox on the port that says give access to the infrastructure VLAN.

23:38.810 --> 23:42.570
That infrastructure VLAN is the crown jewels to your fabric.

23:42.570 --> 23:44.550
Don't give it to just anything.

23:45.310 --> 23:48.590
And the reason why is it gives you access to the underlay.

23:48.870 --> 23:55.650
Even though it's called an infrastructure VLAN, what they did is they set aside a VLAN for accessing the underlay.

23:56.630 --> 24:04.150
When we got into this, we knew that there was ISIS, we knew that things were routed, and we were like, how the hell am I ever going to get my IP address into ISIS?

24:04.450 --> 24:06.310
I was like, how is this going to work?

24:06.490 --> 24:09.670
Well, as it turned out, later on we found out that they do DHCP.

24:09.670 --> 24:12.410
When you have access to the infrastructure VLAN, that's one way.

24:13.050 --> 24:17.310
Another way is they actually learn your IP address, which I'll talk about.

24:18.070 --> 24:21.070
Enrollment of the APICs is automatic, so they do zero-touch provisioning.

24:21.070 --> 24:28.310
Anytime you ever attack a fabric or a network for the first time, look at how they do day zero configuration.

24:28.450 --> 24:30.570
Chances are you might find issues there.

24:32.390 --> 24:40.810
Communications at Layer 2, we saw LLDP, and we know that there are custom TLVs, so we wrote a Scapey plugin to generate these TLVs.

24:41.170 --> 24:44.710
And there's no authentication before them, so what happens if we tweak and replay?

24:44.710 --> 24:48.210
We find that it says, hey, you're a controller.

24:48.610 --> 24:52.390
You have access to the controller endpoint group, and you have infrastructure.

24:52.390 --> 24:53.690
So that's what we did.

24:54.050 --> 24:56.590
And this is what it looks like in the underlay.

24:56.830 --> 24:58.130
So you have the APICs.

24:58.130 --> 25:04.010
The APICs are usually dual-attached to two leaf switches, and then they have a set of subnets that are...

25:04.010 --> 25:15.010
or there's a subnet that's set aside on that leaf switch that is advertised out, and this whole thing is on the underlay IP address range that you'll specify when you first set this thing up.

25:15.470 --> 25:23.470
And you'll notice that it's all completely routed over ISIS, and if we're the attacker, we can do the same thing and represent ourselves up as an APIC.

25:23.470 --> 25:30.130
So we're spoofing ourself to the network and saying that, hey, we're an APIC, and it believes us and allows us onto the fabric.

25:31.410 --> 25:34.830
Once we're on the underlay, we have a much larger attack surface.

25:34.830 --> 25:37.090
We can get access to all of the different APICs.

25:37.090 --> 25:45.250
We can get access to the hypervisors that happen to be attached to the infrastructure VLAN, and all of the switch and APIC DME ports are accessible.

25:45.250 --> 25:48.390
We can get to them, but they're protected by TLS.

25:48.930 --> 25:51.210
They're using mutual authentication.

25:51.850 --> 25:52.790
We need access.

25:52.790 --> 25:56.990
We need some kind of way of getting access to that TLS connection.

25:57.070 --> 25:58.230
What do you think we did?

25:58.310 --> 25:59.430
Anybody guess?

26:00.490 --> 26:02.750
We need a cert and we need a private key.

26:02.750 --> 26:04.290
We could steal it from something.

26:04.290 --> 26:05.430
That's one way.

26:06.550 --> 26:07.630
What's that?

26:08.290 --> 26:08.970
Spoof it?

26:08.970 --> 26:12.650
Well, it has to be issued by Cisco because it's got a trust store.

26:13.410 --> 26:15.090
And, yeah, you steal it.

26:15.430 --> 26:18.690
The DMEs, they communicate policy throughout the fabric.

26:18.690 --> 26:22.050
That includes all of the users and credentials on the APICs.

26:22.550 --> 26:26.870
But we don't have access to the DMEs because we don't have access to TLS credentials.

26:26.870 --> 26:28.690
We don't have the certs and the private keys.

26:28.990 --> 26:37.570
So we looked at the certs, and the certs showed that they were issued by Cisco, and we know that they are issued by Cisco at manufacturing time.

26:37.950 --> 26:40.250
And they have an expiration date way, way, way out.

26:40.510 --> 26:43.230
And there's really nothing else that was really special about them.

26:43.470 --> 26:49.050
And so we tried another private key and certificate that was issued by a Cisco certificate authority.

26:49.790 --> 26:51.430
What do you think we used?

26:58.710 --> 27:05.310
If you're doing a tax against a PKI, keep a cache of certs and private keys available.

27:05.410 --> 27:07.170
You can extract them out of these things.

27:07.170 --> 27:08.130
It's not that hard.

27:08.130 --> 27:09.910
It's hard, but it's not that hard.

27:10.030 --> 27:11.850
It's just basically on flash.

27:11.870 --> 27:13.330
It's kept by Cisco.

27:13.330 --> 27:14.390
It's a certificate.

27:14.390 --> 27:16.230
It's a private key, and it's issued by Cisco.

27:16.230 --> 27:18.130
And it comes from a Cisco PKI.

27:18.470 --> 27:20.330
Not all things are that easy to get off.

27:20.330 --> 27:25.370
We actually have a module called the TAM, the Trust Anchor Module, which is tamper-resistant.

27:25.370 --> 27:29.730
And it's actually programmed somewhere else that's not in a contract manufacturer facility.

27:29.730 --> 27:33.910
And they ship those chips to be embedded on a device.

27:33.910 --> 27:35.590
Those are a little bit harder to get to.

27:35.590 --> 27:38.890
But if it's something that's on flash, you can get to it.

27:39.230 --> 27:40.430
So we use that.

27:40.710 --> 27:42.270
We get access to that key.

27:42.270 --> 27:46.910
And this is a video from soup to nuts of owning an APIC.

27:47.830 --> 27:49.690
And so we're going to get those credentials.

27:49.690 --> 27:53.390
We're going to stick those on the APIC so that we can get access to SSH.

27:53.390 --> 27:56.130
First thing we do is we're going to listen for LLDP.

27:56.630 --> 27:59.470
And you can see that we're now sending LLDP.

27:59.510 --> 28:01.310
And we have access to the endpoint group.

28:01.310 --> 28:03.850
And these are all of the VLANs that we have access to.

28:03.850 --> 28:10.610
Now from that point forward, then we can ping our default gateway that is on the infrastructure VLAN.

28:10.610 --> 28:12.750
And once we do that, we've been learned.

28:12.970 --> 28:15.170
And everybody now knows about us.

28:15.170 --> 28:18.910
The Spines, the Leafs, they all know about that IP address that we're reusing.

28:18.910 --> 28:26.570
Because they redistribute basically ARP into ISIS so that we're able to get discovered.

28:27.090 --> 28:28.950
And then from that point forward, then...

28:29.610 --> 28:31.810
So that's basically what I was telling you.

28:33.350 --> 28:37.030
And now we'll connect to the APIC.

28:37.130 --> 28:38.370
We'll do the same thing.

28:38.370 --> 28:41.750
We're going to create a user with our username and password.

28:41.930 --> 28:43.950
Then we're going to be able to SSH in.

28:43.950 --> 28:47.810
So when you have a username on the APIC, you can SSH in.

28:47.810 --> 28:50.310
You can get access as admin but not root.

28:50.450 --> 28:55.330
So we wanted root access to the APIC so that we could do something that I'll be showing you in a little bit.

28:55.330 --> 29:01.990
And the way we did that, there was a open internal service that you could only get to if you were logged in locally.

29:01.990 --> 29:03.850
It was not an external service.

29:03.970 --> 29:06.370
And it had a command injection vulnerability in it.

29:06.370 --> 29:10.530
And that service ran as root and that gave us access to the APIC as root.

29:10.910 --> 29:14.190
And then once we had that access, then we installed a root kit.

29:14.290 --> 29:15.370
I'll show you that.

29:18.050 --> 29:22.270
Now we've completely withdrawn our LLDP frame.

29:22.270 --> 29:26.550
So we no longer have access to the underlay because we don't want to attract attention to ourselves.

29:26.550 --> 29:28.330
But we want to get access to the APIC.

29:28.330 --> 29:32.930
And the APIC has a VLAN that it sets aside called in-band network.

29:32.930 --> 29:34.450
So that gives us access to the APIC.

29:34.450 --> 29:39.710
And we just netcad it directly in using our port, which is 1337.

29:39.710 --> 29:41.570
And we logged in and that gives us a bind shell.

29:41.570 --> 29:43.730
And that's something that we positioned ahead of time.

29:43.850 --> 29:49.090
And then we run script dev null and that gives us access to an actual sudo terminal so we can run anything we want.

29:49.090 --> 29:51.110
That's kind of a nice trick if you didn't know about that.

29:52.190 --> 29:54.290
Type ID, we see that we're root.

29:54.290 --> 29:57.810
And you'll notice that there's no processes that are listening on port 1337.

29:57.810 --> 29:58.710
They're hidden.

29:59.030 --> 30:03.210
There's also no directory there called rootkit.

30:03.210 --> 30:05.890
And we just log in and there's the subversive rootkit.

30:05.910 --> 30:09.210
The claim to fame with the subversive rootkit, which is really neat.

30:09.210 --> 30:11.690
If you haven't played with it, I strongly suggest you do.

30:11.690 --> 30:12.870
It runs on Linux.

30:13.030 --> 30:18.270
And it does its hooking through the debug registers of Intel.

30:18.690 --> 30:21.150
So you don't actually hook anything.

30:21.150 --> 30:24.050
You don't modify the kernel in any way.

30:24.050 --> 30:27.730
It uses the debug registers to be able to hook the different system calls.

30:27.730 --> 30:29.910
And one of the system calls they have, of course, is write.

30:29.910 --> 30:35.510
And you're hooking that and you're turning it into leetspeak by just turning lulz mode on and lulz mode off.

30:35.510 --> 30:37.010
And you can see the other things you can do.

30:37.010 --> 30:38.110
You can hide files.

30:38.110 --> 30:39.490
You can hide processes.

30:39.870 --> 30:45.870
But, of course, we didn't hide the kernel module even though we probably could have.

30:47.810 --> 30:49.050
With me so far?

30:50.850 --> 30:51.650
Okay.

30:51.690 --> 30:53.170
So after that...

30:53.170 --> 30:55.050
Oh, we're done.

30:55.130 --> 30:57.430
So this is how it worked in summary.

30:57.970 --> 31:02.190
So as a bare metal attacker, we spoofed the APIC VLLDP.

31:02.190 --> 31:04.430
We get access to the infrastructure VLAN.

31:04.490 --> 31:05.790
We use a static IP.

31:05.790 --> 31:07.550
You could have also used DHCP.

31:07.790 --> 31:10.290
And that gives us access to the local switch.

31:10.290 --> 31:12.210
Then we inject our IP into ISIS.

31:12.210 --> 31:12.910
That's automatic.

31:12.910 --> 31:14.870
That was something I was like, how the heck are we going to do this?

31:14.870 --> 31:17.110
Well, it turned out it was a lot easier to do than I thought.

31:17.470 --> 31:19.270
We gain access to overlay 1.

31:19.270 --> 31:21.190
That's the name of the infrastructure VLAN.

31:21.610 --> 31:26.190
We steal a cert from an existing switch or use the cert or key from a phone.

31:26.250 --> 31:28.030
We access the data management engine.

31:28.030 --> 31:31.250
The one that we're interested in is called the policy manager engine.

31:31.350 --> 31:33.490
And we connect to the shard leader for AAA.

31:33.490 --> 31:35.510
We create a local admin user.

31:35.630 --> 31:38.610
We then connect to the APIC over the overlay 1 via SSH.

31:38.610 --> 31:40.010
We SSH in.

31:40.130 --> 31:43.990
Skew the root user SSH keys, which we actually could have done.

31:43.990 --> 31:46.450
We did that through a command injection vulnerability.

31:46.590 --> 31:48.750
That gives us access to the APICs and the switches.

31:48.750 --> 31:51.670
We install a root kit, remove the admin user, and now they're owned.

31:57.330 --> 31:58.490
These are the kinds...

31:58.970 --> 32:00.350
Clap, if you like.

32:00.630 --> 32:01.550
Thank you.

32:03.450 --> 32:05.770
These are the kinds of things that you'll see.

32:06.390 --> 32:09.370
For our customers, you may be wondering, like, why am I doing this?

32:09.370 --> 32:11.610
Why am I talking about Cisco in this in-depth?

32:11.610 --> 32:13.990
I want you all to know that we work really hard.

32:14.390 --> 32:16.170
The ASIC team works really hard.

32:16.170 --> 32:19.650
I'm blessed every day that I get to work with such great people.

32:20.750 --> 32:22.110
It's absolutely amazing.

32:22.110 --> 32:25.370
Some of the smartest people on the earth are in ASIC.

32:25.370 --> 32:26.330
I just love it.

32:26.490 --> 32:27.410
I just go to work every day.

32:27.410 --> 32:28.350
I just love it.

32:29.830 --> 32:30.630
Owned.

32:32.470 --> 32:35.910
We have access to the APIC, but we want access to the endpoints.

32:36.430 --> 32:39.390
In CME, they have VXLAN.

32:39.390 --> 32:41.390
It is mostly standard.

32:41.390 --> 32:43.730
I think that they use a weird UDP port.

32:43.730 --> 32:48.090
But there are a couple of flags in there that says whether or not policy has been applied.

32:48.090 --> 32:49.930
The source policy applied flag.

32:50.030 --> 33:00.450
Once you have access to the infrastructure VLAN, you have direct access to be able to send NCME VXLAN encapsulated frames.

33:00.770 --> 33:05.350
They get routed through the leaf switches, and then they can get to their target.

33:05.350 --> 33:08.750
And you just say, hey, I've already done source policy.

33:08.750 --> 33:09.650
Don't worry about it.

33:09.650 --> 33:13.870
And then the destination leaf switch will forward it on to the destination.

33:15.210 --> 33:17.090
It's just as simple as that.

33:19.690 --> 33:24.870
Once you have that access, for instance, once you send something to it, you can spoof your IP address.

33:25.050 --> 33:28.610
Maybe you may respond somewhere off your network.

33:28.610 --> 33:32.170
Maybe you can get tumbled somewhere else, so then you can respond to it that way.

33:33.870 --> 33:35.510
That's basically all there is to it.

33:35.510 --> 33:36.830
It's quite easy.

33:37.290 --> 33:39.410
Here are the fixes that they did.

33:39.650 --> 33:42.170
XSS, obviously, is very easy.

33:42.170 --> 33:46.090
The XSS vulnerability was actually a DOM XSS vulnerability.

33:46.310 --> 33:47.550
It was not stored.

33:47.550 --> 33:50.350
It was not reflected or anything like that.

33:50.350 --> 33:51.230
It was in the DOM.

33:51.230 --> 33:53.310
So make sure you sanitize.

33:53.310 --> 33:57.670
Don't just rely on your back end to provide safe data to your web app.

33:57.670 --> 33:59.210
They used a single page web app.

33:59.210 --> 34:01.190
Everything was all done through single page.

34:01.570 --> 34:05.270
So sanitizing and escape anything you put into the DOM.

34:05.390 --> 34:07.810
Context, of course, matters, obviously.

34:08.590 --> 34:09.710
Strict mode.

34:09.710 --> 34:12.010
This is one of the mistakes that we made.

34:12.050 --> 34:17.530
They couldn't turn this on without breaking all the existing fabrics, so they had a flag.

34:17.650 --> 34:26.690
It was a nerd flag that we probably couldn't really talk about very much, even to our customers, because we didn't want them to know exactly how hard...

34:26.690 --> 34:28.070
We just said, turn it on.

34:28.070 --> 34:29.430
It's one of those things.

34:29.530 --> 34:36.790
Because if you don't have it turned on, then you're able to do the LLDB attack and then able to get to the underlay.

34:37.990 --> 34:44.870
So strict mode, when you have it turned on, it fixes the LLDP underlay access issue, and it wasn't, unfortunately, backwards compatible.

34:44.870 --> 34:47.090
And that's why it had to be a flag that you turned on.

34:47.090 --> 34:51.070
One of the things that just went out recently was they made it so that it was on by default.

34:51.070 --> 34:54.890
Because this has been three years now, and people probably should have had this on already.

34:54.890 --> 34:56.910
So they turned it on by default now.

34:57.650 --> 35:07.410
So when the host claims to be an APIC over LLDP, the switch will require a random bearer token to be inserted into LLDP TLV to open the underlay.

35:07.410 --> 35:11.430
And the way it learns that token is through connecting to a DME that's on the leaf.

35:11.430 --> 35:16.790
They have an ACL that they put on the port that says you can basically connect to the leaf, but no further.

35:17.850 --> 35:29.310
Once you connect to that, you'll have access to that one DME, and then that's authenticated using mutual TLS, using the certificates that have to be put in a whitelist ahead of time.

35:29.310 --> 35:34.470
Once you have that access, then you have access to the underlay, and only then.

35:35.350 --> 35:39.670
Another thing they did was they strengthened the subject distinguished name checking for certificates.

35:39.670 --> 35:45.470
This is unfortunately very common, guys, especially in embedded products.

35:45.470 --> 35:49.710
Just don't assume because they're using a PKI that they're not actually checking things.

35:49.710 --> 35:51.070
You'd be surprised.

35:51.070 --> 35:57.410
You can just go get a Let's Encrypt certificate, try to connect to something, and then it may say, well , hey, this is on my trust store.

35:57.410 --> 35:58.490
I'm going to allow it.

35:59.150 --> 36:01.270
They may not do the subject checking.

36:01.550 --> 36:08.590
Make sure you look for that because it's been in five products, I think now, so far.

36:09.370 --> 36:13.010
No reason an IP phone should be able to talk to the data management engines.

36:13.090 --> 36:15.410
The admin registers these APICs and switches.

36:15.410 --> 36:28.510
This is actually part of just what they do when they first set up the fabric, is they'll go in and you'll put in the serial number ahead of time, or you'll actually just say, accept this, and it puts that into a whitelist that's actually used for checking this.

36:29.070 --> 36:31.970
This check happens during the initial TLS exchange.

36:32.510 --> 36:41.190
And then IVXLAN spoofing, unfortunately, by design, it's part of the use cases that hypervisors be able to send directly to the leafs.

36:41.190 --> 36:42.830
That's the VLEAF use case.

36:42.930 --> 36:45.030
So, unfortunately, there's not really much you can do.

36:45.030 --> 36:48.530
It's just you really want to protect the infrastructure VLAN from untrusted hosts.

36:48.530 --> 36:49.870
Make sure you do this.

36:49.870 --> 36:57.790
There is a new feature called CloudSec that's on the newer switches that actually does encryption from VTEP to VTEP.

36:58.570 --> 37:07.130
And , anyway, it's something that I'm kind of excited about to see, but it uses something very similar to IPsec between the VTEPs.

37:09.190 --> 37:10.430
Okay, so lessons learned.

37:10.430 --> 37:11.990
Don't expect hardware to play nice.

37:11.990 --> 37:14.670
Someone else's box is plugged into your switch's user input.

37:14.670 --> 37:19.950
Don't ever trust unauthenticated information, regardless of where it's coming from.

37:19.950 --> 37:20.950
You'd be surprised.

37:20.950 --> 37:24.450
Even if you're doing LLDP, you can actually do XSS through LLDP.

37:24.450 --> 37:25.210
Who knew?

37:27.030 --> 37:30.130
Context-sensitive sanitization before inserting into the DOM.

37:30.370 --> 37:33.750
PKIs, public key infrastructures, especially in hardware, it's really hard.

37:33.750 --> 37:36.350
Because once you've done it, you've done it, and you're stuck.

37:37.130 --> 37:39.210
You can't revoke certificates.

37:39.810 --> 37:44.690
You don't have OCSP, the Open Certificate SAS protocol, or CRLs.

37:44.870 --> 37:47.110
Once you're stuck, you're stuck.

37:47.110 --> 37:49.970
You can't really check those kinds of things.

37:50.390 --> 37:51.350
Don't abuse protocols.

37:51.350 --> 37:53.310
LLDP is strictly for discovery.

37:53.310 --> 37:55.110
It's just like Cisco Discovery Protocol.

37:55.630 --> 37:57.650
Link-local discovery protocol.

37:58.910 --> 38:00.590
Any questions now?

38:00.650 --> 38:02.730
How am I doing on time?

38:05.570 --> 38:07.870
I actually got through that faster than I thought.

38:07.870 --> 38:08.550
Yes?

38:15.620 --> 38:20.200
The new Cisco certs that are in Encore, are they going to be taken into account?

38:20.200 --> 38:21.320
I don't know.

38:21.940 --> 38:23.940
You can send me, drop me an email.

38:24.660 --> 38:27.100
Or drop me a Twitter, and I'll see if I can find out.

38:34.460 --> 38:34.960
VXLAN?

38:37.380 --> 38:39.140
VXLAN is data plane.

38:39.440 --> 38:43.640
And the certificates that they do is for control plane or management plane.

38:43.640 --> 38:44.900
So they're kind of different.

38:44.900 --> 38:46.520
They're orthogonal, but they're different.

38:47.220 --> 38:48.340
Any other questions?

38:54.680 --> 39:00.260
The script, what the script does, is it connects, so when we...

39:00.260 --> 39:01.780
Yeah, it gives you a PTY.

39:02.440 --> 39:03.420
A pseudo-terminal.

39:03.680 --> 39:08.000
So normally, if you have a bind shell that's listening on a socket, it doesn't really give you a terminal.

39:08.000 --> 39:10.240
So if you try to run Vim or something like that, it won't work.

39:10.400 --> 39:14.920
So if you run script dev null, that just gives you a PTY, and it doesn't save it anymore, which is really nice.

39:14.920 --> 39:15.380
So...

39:17.540 --> 39:21.720
You'd be surprised how many little tricks that you learn, you know, just from watching other things.

39:24.420 --> 39:26.240
Yeah, I can't run anything.

39:26.240 --> 39:27.980
How do I just run... yeah, script dev null.

39:28.400 --> 39:28.960
Yes, sir?

39:31.460 --> 39:35.440
Are there any similarities between ACI and UCS?

39:35.880 --> 39:39.100
The APIC uses UCS server.

39:39.100 --> 39:47.240
It actually is a re-imaged UCS server that has its own certificate and ID for it.

39:47.240 --> 39:49.500
But other than that, it's just a UCS server.

39:50.960 --> 39:51.740
Good question.

39:51.740 --> 39:52.600
Any others?

40:02.750 --> 40:05.490
Oh, the question was, is where do we run this?

40:05.490 --> 40:07.110
We use testbeds.

40:07.110 --> 40:08.990
So we set testbeds up ahead of time.

40:08.990 --> 40:14.530
That's actually probably one of the most time-consuming parts that we're not actually doing work, is just getting testbeds to work.

40:14.530 --> 40:25.170
And for those of you who are doing, like, red teams or cloud pentests, it's the biggest... I hate doing cloud pentests, because you're always depending on somebody else to set up, like, a dev environment.

40:25.190 --> 40:29.550
And hopefully it's exactly the same as the production environment, and most of the time it isn't.

40:29.550 --> 40:32.070
But what we do is we go through and we try to set up where we can.

40:32.070 --> 40:37.430
We try to set up an on-prem environment that looks fairly complex, you know, and real.

40:44.110 --> 40:45.590
Any other questions?

40:47.130 --> 40:48.850
Any of this interest you?

40:50.670 --> 40:55.050
If you like this kind of work, please apply.

40:55.110 --> 40:57.950
Go to jobs.cisco.com and type in ASIG.

40:57.950 --> 41:01.690
I think there's only a couple jobs on there right now, but we're always trying to hire good people.

41:02.650 --> 41:07.070
Any other questions?

41:07.630 --> 41:14.630
No questions about inner fabric messaging, TLS, leaf switches, spine switches, connections, nothing like that?

41:16.390 --> 41:17.610
Thank you.

41:17.610 --> 41:18.790
Thanks for coming.

