Latest / Blue Security / CISA guidance on securing CI/CD pipelines
Transcript
- 0:06Welcome to the Blue Security Podcast, a weekly podcast for
- 0:10information security defenders where we bring you discussions
- 0:13on best practices, tools, and implementation for enterprise
- 0:16security. Now here are your house for
- 0:19today's show, Andy JA and Adam Brewer.
- 0:22Welcome to this week's episode of the Blue Security Podcast.
- 0:25I'm Andy, your host. I'm Adam, your Co host.
- 0:27We have been going over a bunch of excellent guidance that CISA
- 0:32has been putting out lately, and today we're going to go over
- 0:35another one. So this is a little bit older
- 0:38and it's been on the backlog for topics that I've wanted to talk
- 0:41about. And of course, you know, things
- 0:43have come up. So back in 2023, in June, CISA
- 0:47released some guidance on how organizations can defend and
- 0:51harden their CICD environments, which is their continuous
- 0:54integration and continuous delivery environments.
- 0:57This is often associated with DevOps.
- 1:00And so CICD pipelines and environments have revolutionized
- 1:03the way that we produce and deliver modern software as well
- 1:09as infrastructure. And they've enabled
- 1:11methodologies like DevOps and Dev SEC OPS to help push that
- 1:16shift. Security left mentality.
- 1:19However, CICD pipelines and environments have their own
- 1:22risk, and they represent a large portion of your attack surface
- 1:26if you're using it. And so if you do not secure your
- 1:29pipelines, they can lead to compromise and the abilities of
- 1:32malicious actors to poison those environments downstream.
- 1:35And a key aspect of that is securing the modern software
- 1:39supply chain. So at a high level, the CISA
- 1:41guidance explains how organizations can implement best
- 1:45practices for security into those dev and CICD environments.
- 1:51And the best part is it's written from a tool and vendor
- 1:54agnostic viewpoint. So getting into the specific
- 1:58threats, what are we looking for when we talk about threats to
- 2:02CICD pipelines? There is a comprehensive guide
- 2:06and I'll put the link in the show notes, but there is an O
- 2:09Wasp top 10 CICD security risks. Always great to check out the OS
- 2:16top ten. They have something specifically
- 2:18for CICD pipelines but just at a high level.
- 2:22You could have insecure first party code, and this is code
- 2:25that's checked in by developers, but they contain security
- 2:28related bugs that are not detected by either the
- 2:31developers or a security tooling.
- 2:34And so they're writing code and they check it in.
- 2:37And maybe you don't have a tool that's scanning for it, like a
- 2:40SQL injection or cross site scripting or whatever it is.
- 2:43And so that's a threat. Insecure third party code,
- 2:47that's code that's compiled into a CDCICD pipeline by a third
- 2:51party source such as an open source project.
- 2:54So I can't remember off the top of my head.
- 2:55Maybe you can remember there was that one library a few years
- 2:59ago. Log 4 J.
- 3:01Log 4 J Yep. And that's a perfect example of
- 3:04this right here where there's a library that someone is using
- 3:08and there's a vulnerability in that.
- 3:10And we of course depend on those open source projects to
- 3:15hopefully update them. But we went over the
- 3:18difficulties of open source and you know, the one guy in Kansas
- 3:23who's like maintaining the one library.
- 3:24But when they do update, you want to have a way to detect
- 3:28that that library has been updated and then updated and and
- 3:31make sure that your code is secure.
- 3:33Poisoned pipeline execution. This is exploitation of the
- 3:37development or test or production environment that
- 3:40allows attacker to insert code into it into it when they want.
- 3:44And so maybe they get a hold of a way to get into the library
- 3:47and they inject their own code into it.
- 3:50Insufficient pipeline access controls.
- 3:52As always, identity is one of the attack surfaces, so
- 3:56unauthorized access to source code repository or build tools
- 4:00is a threat. Insecure system configurations
- 4:03and this is where cloud security.
- 4:08Posture management Posture. Management.
- 4:10Thank you, Adam. Cloud security posture
- 4:12management CSPM. Is a big part of it.
- 4:15So various infrastructure, network or application
- 4:18configurations that are vulnerable to known exploitation
- 4:21techniques can be a threat. And so you want to make sure
- 4:25that you have some sort of posture management and you're
- 4:28you're securing the way that everything is configured.
- 4:31Usage of insecure third party services.
- 4:34So using services that are created by an external
- 4:37individual or organization that intentionally or negligently
- 4:41includes security vulnerabilities.
- 4:44And then finally, the exposure of secrets, security keys,
- 4:49compromise or insecure secrets management within the pipeline,
- 4:52such as hard coding access keys or passwords into infrastructure
- 4:57as code templates. And so I'll pause there for a
- 5:00second because that was a lot. Those are just kind of an
- 5:03overview of the threats that you might have.
- 5:07And you know, as we have gone over in this cloud security
- 5:11series, you know, we went over a lot of different tooling that
- 5:15can help secure, you know, like ACSPM or like a key vault.
- 5:19And those are things that you can implement to mitigate
- 5:22against some of these threats. And we're going to go over some
- 5:24threat scenarios as well and some mitigations.
- 5:27But I wanted to pause there and give Adam you a chance if you
- 5:30had any thoughts around and just overall what we've gone over so
- 5:33far. Yeah, I'd say no real surprises
- 5:36in this list and subjects that have come up through organic
- 5:39conversation over the last, what, four years now of doing
- 5:44the show, Andy, where we've, we've probably touched on every
- 5:46one of these at some point or another.
- 5:49Talked about the benefit of, for example, the insecure system
- 5:53configuration, cloud security posture management can help with
- 5:55that. Talking about having secrets in
- 5:57code using things like GitHub Advanced Security or Azure Key
- 6:01Vault can not only detect those secrets in code, but then gave
- 6:04you a safe place to put them. So we, we've talked through a
- 6:07lot of this like you said, through the lens of here's
- 6:10tooling that can help. But I just point out that for a
- 6:13lot of these, yes, although we talked about with secure
- 6:18application development how that needs to be baked in from the
- 6:22beginning, it's not something you can bolt on later, at least
- 6:25not as easily. When we had Tony Jenka on the
- 6:28show many years ago, the author of Alison Bobler and Application
- 6:32Security, she talked about how like if you think of building a
- 6:35house and having to build an addition onto it later, how that
- 6:39costs more than just building that into the house as part of
- 6:41the original plan. And App SEC is kind of like
- 6:44that. And so when you when you think
- 6:46through all these things, obviously having your developers
- 6:50on board with that approach is really important.
- 6:52But you look through some of these items and you think to
- 6:55yourself, that's something software developers may just not
- 6:58be super familiar with. Some of them they would be very
- 7:00familiar with, of course, adding third party libraries into their
- 7:03code. They're going to use that.
- 7:04Why reinvent the wheel? However, some libraries do have
- 7:09vulnerabilities overtime Log 4 J famously, more recently, there's
- 7:12almost a back door introduced in the Xe tooling that actually a
- 7:16Microsoft engineer where Andy and I both work caught that like
- 7:19at the very last minute before that was pushed broadly into the
- 7:22world. So we have to be very aware of
- 7:25that. So the point I'm making here is,
- 7:27although you certainly want your software developers to have a
- 7:31seat at the table to be part of the solution, it takes a
- 7:35village. And this is where us as security
- 7:37professionals, our listeners and viewers of this show can help.
- 7:42Our app dev teams, our software engineers, help them to write
- 7:47and manage not only secure code, but secure pipelines and a
- 7:51secure development chain end to end.
- 7:54And, and there's some of this that to us as security
- 7:57professionals is like really, quote UN quote easy.
- 7:59Like we understand very intuitively, but for other folks
- 8:02may be more difficult. And that's where we have to work
- 8:04together to build solutions. So I think this is a great list.
- 8:08It's interesting how so much this is bubbled up through
- 8:10organic conversation because we've either seen these happen
- 8:13in the real world, we've talked about ways to solve for them
- 8:16over time. And one thing to keep in mind is
- 8:20that we're talking about application development.
- 8:22But if you're thinking about your organization, you might
- 8:25think, well, we don't really do much in application development.
- 8:29However, a lot of organizations today are using a CICD pipeline
- 8:33for infrastructure deployment. So I mentioned infrastructure as
- 8:37code. So if you're using like
- 8:38Terraform or ARM templates for Azure, those are plates that you
- 8:44would use to deploy infrastructure instead of going
- 8:48into like the GUI and clicking. I want a VM that has a Linux
- 8:53operating system, 4 cores, 8 gigs of RAM, and I want it in
- 8:59this area. Like you can code that all in a
- 9:01template and then just push it out in a pipeline.
- 9:06That way it is automated and it's easy.
- 9:09You don't have to click through and so.
- 9:11Repeatable too. It's consistent.
- 9:13You're gonna get the same results every time.
- 9:15Correct. Yeah, there's no worry about I'm
- 9:17clicking the wrong thing. And so there are a ton of
- 9:21organizations that are doing this.
- 9:23They have like Sres, site reliability engineers or DevOps
- 9:27engineers that are specifically because every company is
- 9:30probably using some resource in the cloud to host
- 9:35infrastructure. And so ACDICD pipeline is the
- 9:38future and a lot of organizations are moving to
- 9:40that. And so this is directly a threat
- 9:42to that if you don't secure it. And so not a lot of people think
- 9:46about security when it comes to the pipeline itself.
- 9:49They may think about security on the workload, which we've talked
- 9:52about like the server or the container.
- 9:55And of course, you need to have security there at the end, but
- 9:59along the pipeline as well is what we're really talking about
- 10:02here. So let's talk about a couple
- 10:04scenarios here. A threat actor acquires
- 10:07developer credentials to access a Git repository service, like a
- 10:13stolen personal token, an SSH key, a browser cookie or login
- 10:16password. And this is something that has
- 10:19happened before. In fact, I believe it was Okta
- 10:22where there was a developer or an admin that you know, synced
- 10:26their password to their personal Chrome browser and then that was
- 10:32stolen. And so typically a threat actor
- 10:36will go after like valid accounts on a source code
- 10:39repository or valid accounts on a CICD service or a valid admin
- 10:43account for a server hosting the source code repository.
- 10:46So couple of ways to mitigate this.
- 10:49You want to minimize your use of long term credentials human
- 10:52authentication. You should always use some sort
- 10:55of identity federation and fish resistant security tokens to
- 10:58obtain temporary SSH or other keys and therefore software to
- 11:02software authentication. Avoid using software based long
- 11:07term credentials as much as possible and don't hard code
- 11:11those into your code as well. This one is important, utilizing
- 11:15two person rules for all code updates, so no single developer
- 11:19should be able to check in code without another developer
- 11:23reviewing and approving those changes.
- 11:26This practice not only increases the code quality in general, but
- 11:30it also means that the compromise of a single
- 11:32developer's credentials is much less likely to result in
- 11:36malicious code being successfully checked in.
- 11:38You want to secure your user accounts regularly, audit
- 11:42administrative user accounts, configure access controls under
- 11:45the principle of least privilege and separation of duties, and
- 11:49then audit those logs to make sure that any new accounts that
- 11:51are created are legitimate. You want to implement least
- 11:54privilege policies for CICD access.
- 11:57The CICD pipeline should not be accessible by everyone in the
- 12:00organization. And if someone requests access
- 12:03to it, they should not automatically receive access to
- 12:06all the pipelines, only limited access within certain privilege
- 12:09to the ones that they need. And then of course, implement
- 12:12network segmentation. I mean, this is this is pretty
- 12:15much a security one O 1, right? Define a demilitarized known
- 12:19that eliminates any type of unregulated communication
- 12:22between the networks filter the traffic to prohibit ingress and
- 12:25egress communications with known IP, malicious IP addresses.
- 12:30You know a couple ones that are kind of no brainers.
- 12:32But to me, I think in general, this is an area that a lot of
- 12:39security professionals today may not have a lot of visibility,
- 12:43may not have a lot of knowledge around it.
- 12:45And if you think about how security has kind of evolved,
- 12:50like way back in the day, right, it was all about the perimeter
- 12:53network security. And so a lot of network
- 12:55engineers who had a security leaning became, you know, the,
- 13:00the security engineer. And then as the networks kind of
- 13:04dissolved over the years, it became identity and endpoints.
- 13:07And so a lot of people who specialized in identity and
- 13:10endpoints like Adam and myself became, you know, more security
- 13:15focused and now are the security focus of today.
- 13:18And I think this is a newer area that, you know, folks like
- 13:23myself may not know a lot about, may not have a lot of visibility
- 13:27on it. You know, we may not have access
- 13:29to any of the CICD pipelines if we go to an organization because
- 13:32it's not typical. And so one, I think it's
- 13:34important to gain visibility, gain knowledge around it, but
- 13:37also maybe work with someone who's in that area.
- 13:40Maybe there is a dev SEC OPS engineer or an SRE engineer who
- 13:45leans more security. They have knowledge of how the
- 13:48pipelines work and maybe you work with them to secure the
- 13:52pipeline. So maybe that is going to be the
- 13:54next area, just like APSEC. I think APSEC is another area
- 13:58where if you're not a developer, you may not understand all of
- 14:01the code and things that go into it.
- 14:03And so maybe a developer who is more security leaning, who, you
- 14:08know, focuses on security, becomes the APSEC person.
- 14:12So I mean, there's just so many areas, but I think this is
- 14:15something that everyone should at least have a basic
- 14:18understanding that obviously needs to be secured and then
- 14:21some rules around how to secure it.
- 14:24Yeah, I agree with everything you just said there.
- 14:26It's still an area I think that is under secured at most
- 14:30organizations today. And you articulated the reasons
- 14:33why really well in that. It's an area where we kind of
- 14:38feel uncomfortable because we're just not as knowledgeable about
- 14:42it. And so we don't want to go in
- 14:43and start being the proverbial bull in the China shop and
- 14:46messing up stuff because you know that that job is hard
- 14:49enough. Writing, writing software is
- 14:51difficult. You don't need the security team
- 14:53that doesn't know what they're talking about come in and make
- 14:55your life much more difficult. So certainly we do want to tread
- 14:58lightly. We want to kind of going off my
- 15:01rant from several weeks ago now be that learn it all mindset
- 15:05that that growth mindset and how much can we learn here?
- 15:08But but again, I like the idea you talked about Andy of maybe
- 15:11having that kind of bridge person who bridges the gap
- 15:14between software development and security.
- 15:17They speak both languages. They're kind of our translator
- 15:20and help us implement common sense reasonable policies
- 15:23because everything you just talked about here, like they all
- 15:26kind of sound like no brainers. We want to limit long term
- 15:29credentials, make sure we're doing kind of real time
- 15:33validation of identity every time someone signs in.
- 15:36I have two two people review all code before it gets pushed into
- 15:40production, make sure our accounts are secure, implement
- 15:44least privilege, implement network segmentation and and
- 15:47like block malicious IPS. Like it all sounds like one O 1
- 15:50stuff, but we we have different implementation control planes
- 15:54for a lot of this that we may be less familiar with.
- 15:56And of course we want to do this as effectively as possible, but
- 16:01we should really measure twice and cut once here.
- 16:03OK, so let's talk about another very common scenario.
- 16:06A supply chain compromise of an application library tool or
- 16:10container image in the CICD pipeline leads to a poisoned
- 16:13Devsec OPS environment. The lock 4J is a perfect
- 16:16example. Or if there's a container image
- 16:19that that gets, you know, pushed into the pipeline.
- 16:22So some mitigations and recommendations around this.
- 16:25You like, you want to restrict untrusted libraries and tools.
- 16:28So only use software tools and libraries, artifacts from secure
- 16:32and trusted sources. And a lot of developers in the
- 16:36developer mindset, they, they just want things to work.
- 16:39If they're not security focused, their, their job is to make the
- 16:43code work. And so they might just go and
- 16:46find some library on Reddit or some library wherever and they
- 16:51just pull it in and they're like, yeah, all of a sudden it
- 16:53works. And they're like, yeah, we're
- 16:54going to use this. So you want to vet it, you want
- 16:57to make sure that stuff is signed.
- 16:59Employing tools from trusted sources will help you minimize
- 17:02the threats that are opposed to a CICD pipeline and prevent any
- 17:07type of potential exploitation. Adopt A never trust, always
- 17:10verify approach towards software because that'll reduce your
- 17:14overall attack surface. You want to analyze committed
- 17:16code. So you know, we talked about the
- 17:18two person rule there, but also just securing the pipeline
- 17:22involved just analyzing the code that's being committed.
- 17:25So this can be used either manually or done manually, or
- 17:29you can use some sort of automated tool to do it.
- 17:32Automated tools are better, They can identify potential security
- 17:35vulnerabilities in the code and track it over time.
- 17:37And if you analyze the code, it ensures that only approved
- 17:41changes are made to the code base and that any potential
- 17:43security vulnerabilities are addressed before they can be
- 17:46exploited. Implement EDR.
- 17:48I mean, that's endpoint detection and response.
- 17:50Of course, you know, you should have some sort of EDR tool not
- 17:54only on the workloads, but also on the endpoints that the
- 17:57developers are working on, because of course their own
- 18:00endpoints can get compromised as well.
- 18:02You want to keep your CICD tools up to date, just like any other
- 18:05software. CICD tools can also contain bugs
- 18:09and vulnerability. For example, Visual Studio.
- 18:13Visual Studio contains bugs all the time.
- 18:15I used it as a text editor a lot of times on my Intune managed
- 18:19Mac. And one of the things that
- 18:22Microsoft actually does is they saw every single time that
- 18:27Visual Studio pushed on an update and they forced me to
- 18:29update that application because they know one.
- 18:34The application is a common tool that developers use to use to
- 18:39write code in and and if there are bugs that are exploitable
- 18:43within the software itself, then of course you need to update.
- 18:46So just like any other vulnerability management, the
- 18:49tool you're that you're using to write the code should be
- 18:51updated. And then of course, maintain up
- 18:54to You should have some sort of vulnerability management
- 19:02program, pretty basic, but a lot of times when it comes to people
- 19:07who are working and writing code or you know, maybe they don't
- 19:10restart their machine often they're in a workflow.
- 19:13You know, these are things that we have to build into the
- 19:16culture that we understand it needs to be updated.
- 19:19Like for me at Microsoft, when I get a notification on my phone
- 19:25that says the iOS operating system is out of date, I don't
- 19:29put it off. I I just pretty much look at
- 19:32anything that I need to have open.
- 19:35I finish it out and then I restart the phone because I know
- 19:39that if I don't, I'm going to lose access to my e-mail, I'm
- 19:44going to lose access to company data.
- 19:45So you build that culture in that you have these warnings,
- 19:49you have these pop ups and the employees, you know, the users
- 19:54understand that this is part of the workflow.
- 19:58They just have to update. Yeah.
- 20:02You know, I don't want to go off on a tangent here, but on the
- 20:05last thing you just said, it made me think about how a lot of
- 20:10organizations give actually relatively permissive update
- 20:13windows, like where you have 7 days before you need to install
- 20:17the update and then we'll force you to update.
- 20:19I don't think that's effective. And I realize I'm going on a
- 20:22huge tangent here, but just since you brought it up, what I
- 20:25see people do when they have a long time to defer it is they'll
- 20:28defer it like upfront, then forget about it.
- 20:31And then all of a sudden they'll hit like the end and it's a
- 20:34force update and they get frustrated with it.
- 20:37And it's partly they're frustrated at themselves because
- 20:39they know they've had a long window to do it, but they're
- 20:42frustrated like they haven't been reminded.
- 20:44And it, it just kind of became out of mind and now all of a
- 20:47sudden you are really disrupting their work.
- 20:50And so I would almost argue just in in a sense of human
- 20:52psychology to where if you have a less permissive update cycle,
- 20:56I know because I'm doing some prerelease testing of some
- 21:00hardware and software at Microsoft, I have very short
- 21:03update windows. Like I'm required to do it, I
- 21:06think within 24 hours. Sometimes it's even less than
- 21:08that. And so like when I get the
- 21:10little icon near the the system tray in, in Windows 11 and it's
- 21:14indicates an update's available, I pretty much like, like you
- 21:17said, Andy, find a stopping point and do it immediately.
- 21:20And I almost think culturally that is a better approach than
- 21:23giving like a seven day window and then having people get mad
- 21:26when you force reboot them anyways.
- 21:27Like if you're going to force reboot them, if it's one day or
- 21:29seven days, it doesn't really matter.
- 21:32But sometimes having a shorter window and getting people
- 21:34accustomed to that makes them more take more immediate action
- 21:38of like, OK, sometime in the next like hour, I need to find a
- 21:41window to reboot this now. And I feel like that's more
- 21:44effective or could be more effective than giving them a
- 21:47long window where they forget. Anyhow, that's a tangent.
- 21:49I want to go back to what you were talking about South supply
- 21:52chain compromise. This is our second scenario.
- 21:55And of course, we talked about log 4 J very famous one off the
- 21:58top of the show. And and you talk through like
- 22:01adopt A never trust, always verify approach to any libraries
- 22:05you're going to build into your code to any any third party
- 22:07libraries you're going to link out to.
- 22:08That sounds great in theory. I will acknowledge that in
- 22:12practice that's difficult because so much of modern code
- 22:16we run everywhere is built on all sorts of third party
- 22:19libraries. And many of them are open source
- 22:21libraries where we've seen either inadvertent
- 22:25vulnerabilities in the case of log for J or malicious
- 22:29vulnerabilities in the case of the XE tools where those have
- 22:31been built in. And again, just referencing our
- 22:34APSEC guru, Tanya, who came on the show many moons ago now, she
- 22:39talked about how there's this false narrative that open source
- 22:43software is inherently more secure because security fairies
- 22:47will float through open source code repositories and go look
- 22:50for vulnerabilities. That's not reality.
- 22:52People have mortgages to pay and mouths to feed and need a roof
- 22:56over their head. And so they're going to go, if
- 22:57you're a security researcher, to where you make money.
- 23:01And that tends to be commercial software vendors like our
- 23:04employer as well as many others who pay money if you go find a
- 23:08vulnerability and report it to them with the proper reporting
- 23:12process, if you follow the the responsible, responsible
- 23:16disclosure. That's what I was looking for.
- 23:18Yeah, bug bounties. So we have this challenge in
- 23:20modern software development where we rely on a ton of open
- 23:23source libraries that maybe don't have that same level of
- 23:26scrutiny, but but it's just the standard practice.
- 23:29And so like moving away from that acknowledge that's really
- 23:33difficult. So at least maybe you stay with
- 23:35the most popular open source libraries or open source
- 23:38libraries that are widely used because at least if there is a
- 23:43vulnerability in them, you're not alone and you may not be the
- 23:46most attractive attack surface like that proverbial.
- 23:48You don't have to outrun the bear.
- 23:50You just have to not be the slowest human kind of thing.
- 23:53In some cases. At least there's safety in
- 23:55numbers there if you're on a more popular open source
- 23:58library. But I think the other changes
- 24:00again, are are reasonable throughout, keep your software
- 24:03updated, keep your CICD tools updated, make sure you're
- 24:06analyzing the code and again, using things like code scanning
- 24:10solutions or code security solutions like GitHub Advanced
- 24:13Security to take a look at that as well.
- 24:15And then, you know, EDR, all the things.
- 24:17Of course, if it can run an EDR agent, it probably should, and
- 24:20that's helpful too. So yeah, I think overall strong
- 24:23advice. But again, and I don't mean to
- 24:25sound like a broken record here, but none of this is really
- 24:29surprising, But I think, again, as security professionals, it's
- 24:32just a matter of not being that bull in the China shop,
- 24:35understanding the environment before we go in and start
- 24:38mandating a bunch of changes. But ultimately these are
- 24:41solvable problems and I think reasonable things we could get
- 24:45done at our organizations without too much gnashing of
- 24:49teeth and too much finger pointing and upsetting other
- 24:52parts of the company. And then we'll end the show with
- 24:54just some other general mitigations and hardening that
- 24:57SISA recommends and and we'll have the link to the guidance.
- 25:01Of course, in the show notes, there's more detail on all of
- 25:04these different things that we're talking about, but some
- 25:07general mitigations always use NSA recommended cryptography
- 25:10because, of course, the use of weak or outdated cryptographic
- 25:14algorithms can pose a threat to the pipelines.
- 25:16You want to add the signature to your configuration.
- 25:19If you implement secure code signing, you'll be able to
- 25:23establish digital trust within the pipeline and so ensure the
- 25:26code is always continuously and properly signed and that
- 25:29signature is verified throughout the CEICD pipeline, regardless
- 25:33of the stage of development. If the signature does not
- 25:35validate, investigate the cause of the validation issue.
- 25:39So this could be a minor configuration problem or a sign
- 25:42of a larger breach. Secure secrets.
- 25:46Make sure that you are secure handling of secrets, tokens and
- 25:49other credentials that are crucial to the CICD pipeline.
- 25:52Never pass secrets in plain text anywhere in the pipeline.
- 25:55Ensure secrets passwords, private keys are never embedded
- 25:59in the software where they can be reverse engineered out and
- 26:02most modern CICD tools will come with a secrets management tool
- 26:06solution, which means that the CICD tool can be securely store
- 26:10the secrets and pass them using an indirect reference within the
- 26:13pipeline. And then finally integrates
- 26:16security scanning as part of the CICD pipeline.
- 26:18We've talked about scanning, but there's a multitude of different
- 26:21types of scanning so you have static applications scanning
- 26:24where you're scanning the static code in an analysis tool to
- 26:29build in the build stage to check the code for any type of
- 26:32common security vulnerabilities. Registry scanning, which is
- 26:35those container images, every time a Canadian image is pulled
- 26:38into the pipeline, make sure you're scanning that registry.
- 26:40And then dynamic security testing.
- 26:43So this is a little bit more advanced, but you want to deploy
- 26:47an instance of a newly built application in a testing
- 26:50environment and then run tests against those applications.
- 26:53There are tools that can do this in an automated fashion, but
- 26:57even those tools can also have mistakes.
- 27:00So manual review is also important when you're doing this
- 27:03type of testing in the code, when you're looking at it.
- 27:08You know, we haven't talked a lot about tooling, but I'll just
- 27:11give a couple examples, right? Like you do want to have a tool
- 27:15that's built into the actual CICD tool that the developers
- 27:21are using. It's integrated, like an example
- 27:23would be GitHub Advanced Security.
- 27:25There's other ones like Vericode and so on and so forth, but it's
- 27:28part of the pipeline. Every, you know, not only is it
- 27:31scanning the code as they're really like coding it and typing
- 27:33it, but also every time they commit the code, it's scanning
- 27:36it. And then you can have other ways
- 27:39to, you know, scan the code. Vera code was, it was a tool
- 27:43that I used in the past. You know, I'm not endorsing it
- 27:45or anything, but it was a great tool.
- 27:46You can do static scanning of a code that can do dynamic
- 27:51scanning of the code. And then there are other tools
- 27:54that you can use even after the application has been either
- 27:57deployed in a test environment or deployed in prod.
- 28:01You can have bug bounties. Bug bounties are a great way to,
- 28:05you know, outsource that. That testing great tool that
- 28:09I've used in the past is something called Bug Crowd where
- 28:13it's over the whole program is overseen by the folks add bug
- 28:18crowd, but they have independent security researchers that can
- 28:22pen test your application within there and then you can pay them
- 28:26bounties that are you know vetted by the bug crowd folks
- 28:31And there's other ones out there as well where you can basically
- 28:34Crowdsource your application testing.
- 28:35So you do want to, you know, not only have it from the code
- 28:39itself on the endpoint, from the developer through the pipeline,
- 28:42but all the way to production and then continue to test that
- 28:45because there might be something more eyes, fresh set eyes might
- 28:49be able to find something that was missed along the way.
- 28:53Again, just some some good mitigations here.
- 28:56The cryptography is a good call out, making sure you're up to
- 28:59date there with the cryptographic methods you are
- 29:02using in here. And I like this, the signature
- 29:04throughout, obviously that's a great way to validate if someone
- 29:07has come in and tried to insert code in there.
- 29:09I believe that was the SolarWinds incident that would
- 29:12have detected that. So, you know, you, you can go
- 29:15through all these recommendations and you can map
- 29:18them to like, ah, yes, remember this incident would have stopped
- 29:20that. Ah, yes, remember this.
- 29:22We're learning, right? We're trying to constantly get
- 29:25better. So this is cool.
- 29:26I just say just to kind of summarize and Andy, you made
- 29:29some of these points earlier in the show, but this is an area
- 29:33that I think orgs have opportunity to become more
- 29:37mature in. And we've seen those shifts over
- 29:39time, right where you talk through it, how it started with
- 29:42network security and then it pivoted to identity and
- 29:46endpoint. And this is maybe that next step
- 29:48of moving to dev SEC OPS and and helping to become really
- 29:53regimented in how we implement a lot of the security tooling we
- 29:56use, but we also need clean and secure pipelines in order to
- 29:59accomplish that. And so this is an area where we
- 30:02can partner with the folks who run a lot of this.
- 30:05If you have application development in house.
- 30:07If you don't, again, infrastructure as coding may be
- 30:10using it there. Either way, make sure we ask a
- 30:12lot of questions and we learn a lot before we start throwing our
- 30:15weight around. You know, we just, if we get
- 30:17involved and we ask questions and we learn the tools, you
- 30:20know, Andy and I did our cloud security series recently where
- 30:23we went through a lot of the tools in Azure.
- 30:25Be familiar with what's out there, what's available to help
- 30:28is a lot of touring. The CSA guidance is vendor
- 30:30agnostic. So this is a great way of just
- 30:33kind of understanding what the areas of opportunity are and
- 30:36what, what the general format of the tools looks like.
- 30:39And then you can go vet out vendors and and find the ones
- 30:41that's going to be the right fit for you.
- 30:43So I think we all, coming off a show like this or the CSA on
- 30:47guidance have homework to do. But with homework comes
- 30:51opportunity and the opportunity to make a difference for our
- 30:54organizations. And so this is cool where
- 30:56cybersecurity, as we all know, is a never finished effort.
- 30:59And here's another area where we can help make our organizations
- 31:04more secure and ultimately do our jobs.
- 31:06And that's really exciting. Yeah, absolutely.
- 31:09All right. Well, that's our show for this
- 31:10week. Thanks for watching and
- 31:12listening. As always, our contact
- 31:13information as well as the links for all the documentation that
- 31:18we went over today will be in the show notes.
- 31:20If you have any questions or topics you want us to talk about
- 31:24in the future, please e-mail us. Thanks.
- 31:28We'll talk to you guys next week.
- 31:29Thank you for listening to the Blue Security Podcast.
- 31:31Please check out the show notes, catch up on episodes you may
- 31:34have missed, and subscribe so you don't miss any future
- 31:37episodes. Find Andy on Twitter at a Jaw
- 31:40Zero and Adam at AJ Brewer. See you at our next episode.