start	end	text
0	5920	Hi everyone, my name is Andy. I'm going to present you with some offensive security testing.
7460	13520	In this presentation I will briefly introduce you to the ground segment and the software that we
13520	19260	use on it. I will focus on one particular software which is the mission control system
20360	27520	and I will show you some vulnerabilities which we have found on those software applications
27520	32440	and then give you a couple of demos on how we managed to exploit them.
34180	37460	Ground segment consists of many interconnected components
38090	49250	or elements. You can see on this orange part where exactly it lies in the space mission.
49780	54340	It consists of different elements. All those elements perform different functions
54920	59920	but they all depend on each other either by receiving input from or sending outputs to
59920	65080	other components. However, most of those components they don't require any user interaction
65080	71020	and this is what brings us to the mission control system which is the main interface.
72160	79340	It is the main interface between the ground station and other components. It also serves as
80140	87020	primary interface between the spacecraft controllers and the spacecraft itself
87740	94180	which I would argue makes it the most vulnerable system in the whole ground segment.
94220	98900	As you know the weakest link of every information system is humans.
100140	106300	For decades the space missions were operated from dedicated mission control rooms
107260	113620	accessible only by the spacecraft controllers.
114040	117020	This however has changed recently mainly due to COVID.
118980	124740	The organization started opening up and letting their users or their spacecraft operators to
125260	131640	conduct operations remotely. This of course creates a new attack surface for the mission
131640	136920	control system which is usually a very outdated software and vulnerable to typical
138520	143170	vulnerabilities which we have on any other software that we use on a daily basis.
143820	150640	So what is being done about it? From the space community perspective obviously we expand
150640	159220	strategies to include security aspects. We impose security policies and then we also introduce
159220	166060	security requirements to our systems. However I don't think it's gonna be enough at this point
166060	171320	and as we will see later there is one very specific element that is missing into those
172520	175950	into the actions which is the offensive security testing.
178640	184840	So every organization has their own mission control system. They try to develop their own
184840	191460	software because you know what as they say the space is hard right so they have to do it
191460	198040	themselves. So some of that software is open source so what we have done we decided to have
198120	204920	a look at it and see how they perform from the vulnerability standpoint. And here is what
204920	209720	we have found out. Full disclosure all those vulnerabilities have been already disclosed
210280	216780	using the contacting the vendor and they have been already addressed and
218180	224680	and all of them have CVE assigned. So on NASA OpenMCT we have found a couple of
224680	232560	vulnerabilities such as prototype pollution, XSS and CSRF. On the IMCS which is another mission
232560	238960	control system it is one of the more established ones. We have found a few more vulnerabilities
238960	245160	such as directory traversal, arbitrary file deletion, session hijacking and a few XSS
245160	252560	vulnerabilities. And then on NASA AIT core we have found and NASA AIT core is like a framework to
252560	259360	develop ground segment software by different missions. We have found SQL injection, a few
259360	265880	local code executions and also realized that the encryption in the communication is completely
265880	271600	missing. So as you've seen before that most of those vulnerabilities they don't have that
272540	277420	much of an impact on the mission. However this is where the training of vulnerability is going to
277420	283420	play. And in case of the IMCS we decided to combine a directory traversal, session hijacking
283980	290340	and XSS. And that led us to quite severe sensitive information disclosure because now
290900	295500	the attackers can when the XSS is triggered the attackers can actually retrieve
295500	299320	any arbitrary file that is stored on the IMCS server.
301020	307980	So here is a let's have a look at typical scenario. So this is like a very high level
307980	311660	overview of a space mission. You have a space segment from right to left you have a space
311660	316400	left you have a space segment. There is a ground station, there is the IMCS which is the mission
316400	323960	control system in subject that is used by Bob to send telemetry, send telecommands and receive
323960	329600	telemetry from spacecraft. We also have Alice that is working with Bob and the whole organization
329600	338060	has a publicly facing website. Now we also have an attacker and that has a C2 server. Now as it
338060	343440	usually goes there is a recon and phishing campaign. The adversaries learn about Alice from the
343440	349260	public website. They decide to target her with phishing campaign.
350580	356320	Alice takes the bait. Unfortunately she clicks on a link or opens a word document
356320	363580	and that deploys the C2 beacon on her workstation. This way making her workstation compromised.
366790	370250	The attackers now have access to her workstation. They learn about Bob
371150	376330	from her emails and they decided to target Bob with an internal phishing campaign.
376510	383570	They send him an email with some payload that would trigger the XSS and they do it as Alice.
385130	392430	So Bob trusts Alice. He executes the payload that triggers the XSS. That XSS then because
392430	398870	there is a session hijacking vulnerability and the traversal director vulnerability
400390	411070	that triggers the... this lets the attackers to retrieve any arbitrary file on the NCS server.
411550	416550	Now if Bob has access to the internet, the files can be directly retrieved and sent to
416550	422710	attacker workstation. Otherwise if Bob is behind the firewall or is using VPN,
423350	429390	we can use Alice's workstation as a proxy and then retrieve the files using the C2 beacon.
431330	435830	So I have prepared a short demo how that would look like in practice.
438940	446040	So what you will see here, this is the exploit we developed. It generates a payload that will end up
446640	453860	being sent to the Bob and Bob will actually use that payload and because he thought that
453860	459700	it was received from Alice, load it on the NCS and then that would trigger our exploit chain.
463080	471140	So first this exploit generates the payload, which is called XMILJS and also starts the HTTP server.
472060	480300	Bob is gonna load that file on the NCS server. Imagine that is one of the telemetry displays
480300	491640	that Alice decided to share with him. So he loads the file and he decides to open it
492740	500880	and that's all he sees. Now under the hoods there was an XSS triggered that would retrieve the file
500880	506140	and then send it back because of the directed traversal and send back the content to the
506140	511960	HTTP server that was started by the attacker.
513340	519980	So here like in any example of proof of concept, you can see we got the access to
519980	527220	etc password file content. So combining those vulnerabilities is actually quite easy so
528560	530780	the whole exploit is easy.
547250	554810	So next up is the vulnerability chain, the exploit chain for NASA IIT Core. Combining
554810	559370	one of the local execution, a code execution and missing encryption, we managed to
559930	566290	conduct a man-in-the-middle attack and inject our own payload into the communication
567950	573050	string which then is triggered on the telemetry client and then is executed,
573050	582530	giving us the reverse shell. So I'll quickly start another demo and explain what you see.
589590	597030	So basically what you see here on the top left side you have telemetry client,
597570	605450	on the left bottom side you have telemetry simulator, that is both are provided by the
605450	611310	IIT Core. On the right side you have our exploit on the top and then on the bottom side on the
611310	616490	right bottom you have the NESCAS list that is going to grab the or is going to receive the
616490	624890	reverse shell. So we start the telemetry client first on the on the left side.
626590	632370	Now this is what would normally be happening on the mission control or on the ground station.
635650	641270	Then we start telemetry simulator which will generate some telemetry packets.
642690	649270	As if they were coming down from spacecraft. We start our NESCAS listener and you can see on the
649270	653130	left hand side on the left hand side we already have started receiving some telemetry from the
653130	668860	simulator. Then we run our exploit that is conducting the man-in-the-middle attack and
669460	673900	then the first frame, so we have injected our frame and the first frame, so the first frame
673900	679700	that is sent from telemetry simulator to the ground station is caught by the man-in-the-middle
679700	686340	attack. There we injected our payload which you can see down here as well and that was actually
686340	692940	executed and it was triggered and it gave us the reverse shell to the telemetry client
692940	722820	running on the mission control. So that's another proof of concept. Sorry about that.
729330	737410	So just for reference we have this is split between static and dynamic analysis which we
737410	743290	have done on those systems. It is still important to conduct static analysis because as you can see
743290	747890	the log hanging fruits and many other vulnerabilities are found using those but
748410	753490	static analysis will not catch everything so you have to conduct the
753490	758390	dynamic analysis and then you have to try to conduct the exploitation phase.
760050	764450	In case of SCOS2000, SCOS2000 is one of the main mission control systems developed by
764450	770250	European Space Agency. We haven't done any extensive analysis on the system, any vulnerability
770250	776950	research. We only run the flow finder on it and using the static code analysis you can see
777670	783750	I'm pretty sure that at least one of those almost 2,500 buffer overflow vulnerabilities would be
783750	793040	exploitable. So in conclusion, the point I'm trying to make is that the space applications
793040	800000	are still not properly being tested from the offensive security standpoint. The best way is to
800540	806720	hire a service to do it properly or you can also try to do it yourself but you have to do it and
806720	813700	you have to include it in your frameworks and you should do it before the adversaries do it for you.
814920	820960	So as I mentioned before, all that research was already published so here you can find, I guess
820960	826900	the slides will be provided afterwards so you can have a look at the publications. Otherwise,
826900	831320	if you want the links today, you can hit me up after the talk and I'll give it to you.
832960	835180	And that was it. Thank you very much.
