{
	"id": "15a0226c-6814-4e49-92b3-17f37d7adc0a",
	"created_at": "2026-04-06T01:32:09.220019Z",
	"updated_at": "2026-04-10T13:12:49.268827Z",
	"deleted_at": null,
	"sha1_hash": "5d27e832fac09a714eeaa0a3563177894bdd9fb8",
	"title": "Inter Process Communication (IPC)",
	"llm_title": "",
	"authors": "",
	"file_creation_date": "0001-01-01T00:00:00Z",
	"file_modification_date": "0001-01-01T00:00:00Z",
	"file_size": 134492,
	"plain_text": "Inter Process Communication (IPC)\r\nBy GeeksforGeeks\r\nPublished: 2017-01-24 · Archived: 2026-04-06 00:47:31 UTC\r\nLast Updated : 29 Jan, 2026\r\nInter-Process Communication or IPC is a mechanism that allows processes to communicate and share data with\r\neach other while they are running. Since each process has its own memory space, IPC provides controlled\r\nmethods for exchanging information and coordinating actions. It helps processes work together efficiently and\r\nsafely in an operating system.\r\nIt helps processes synchronize their activities, share information and avoid conflicts while accessing shared\r\nresources.\r\nThere are two method of IPC, shared memory and message passing. An operating system can implement\r\nboth methods of communication.\r\nExample: A simple example of IPC is a bank ATM system, where one process reads the card and PIN, another\r\nchecks the account balance, and a third dispenses cash. These processes communicate and coordinate to complete\r\nthe transaction correctly.\r\nCommunication between processes using shared memory requires processes to share some variable and it\r\ncompletely depends on how the programmer will implement it. Processes can use shared memory for extracting\r\ninformation as a record from another process as well as for delivering any specific information to other processes.\r\nhttps://www.geeksforgeeks.org/inter-process-communication-ipc/#:~:text=Inter%2Dprocess%20communication%20(IPC),of%20co%2Doperation%20between%20them.\r\nPage 1 of 4\n\nShared Memory\r\nIn the above shared memory model, a common memory space is allocated by the kernel.\r\nProcess A writes data into the shared memory region (Step 1).\r\nProcess B can then directly read this data from the same shared memory region (Step 2).\r\nSince both processes access the same memory segment, this method is fast but requires synchronization\r\nmechanisms (like semaphores) to avoid conflicts when multiple processes read/write simultaneously.\r\nExample: Multiple people can edit the document at the same time in shared google doc.\r\nMessage Passing\r\nMessage Passing is a method where processes communicate by sending and receiving messages to exchange data.\r\nOne process sends a message and the other process receives it, allowing them to share information. Message\r\nPassing can be achieved through different methods like Sockets, Message Queues or Pipes.\r\nMessage Passing\r\nIn the above message passing model, processes exchange information by sending and receiving messages\r\nthrough the kernel.\r\nProcess A sends a message to the kernel (Step 1).\r\nThe kernel then delivers the message to Process B (Step 2).\r\nHere, processes do not share memory directly. Instead, communication happens via system calls (send(),\r\nrecv(), or similar).\r\nThis method is simpler and safer than shared memory because there’s no risk of overwriting shared data,\r\nbut it incurs more overhead due to kernel involvement.\r\nExample: Multiple people send updates to a group chat, but each message goes through the server before\r\nothers see it, like processes sending messages instead of directly sharing memory.\r\nhttps://www.geeksforgeeks.org/inter-process-communication-ipc/#:~:text=Inter%2Dprocess%20communication%20(IPC),of%20co%2Doperation%20between%20them.\r\nPage 2 of 4\n\nPlease refer Methods in Inter process Communication for more details.\r\nProblems in Inter-Process Communication (IPC):\r\nInter-Process Communication (IPC) faces challenges when multiple processes share resources. Improper\r\nsynchronization can cause race conditions, deadlock, and starvation, while shared data may suffer data\r\ninconsistency. IPC also adds overhead and can raise security issues. Managing many processes can lead to\r\nscalability problems.\r\nSome common classical IPC problem are:\r\nDining Philosophers Problem\r\nThis problem illustrates deadlock and starvation. The Dining Philosophers Problem involves five philosophers\r\nsitting around a table, each needing two forks (shared resources) to eat. If all philosophers pick up one fork at the\r\nsame time, none can eat, resulting in deadlock.\r\nSolution\r\nUse semaphores or monitors to control access to forks.\r\nAllow only one philosopher to pick forks at a time or limit eating to four philosophers.\r\nEnforce an order of picking forks to avoid circular wait.\r\nPrevents deadlock and starvation.\r\nProducer–Consumer Problem\r\nThis problem deals with synchronization and buffer management. The Producer–Consumer Problem describes\r\nproducers generating data and placing it in a shared buffer, while consumers remove data from it. The main\r\nchallenge is preventing producers from adding data to a full buffer and consumers from removing data from an\r\nempty buffer.\r\nSolution\r\nUse mutex to ensure mutual exclusion on the shared buffer.\r\nUse counting semaphores to track empty and full buffer slots.\r\nProducer waits if buffer is full; consumer waits if buffer is empty.\r\nEnsures proper synchronization and data consistency.\r\nReaders–Writers Problem\r\nThis problem focuses on concurrent access to shared data. The Readers–Writers Problem allows multiple\r\nreaders to read data simultaneously, while writers require exclusive access. The challenge is avoiding starvation of\r\neither readers or writers.\r\nSolution\r\nUse reader–writer locks or semaphores.\r\nhttps://www.geeksforgeeks.org/inter-process-communication-ipc/#:~:text=Inter%2Dprocess%20communication%20(IPC),of%20co%2Doperation%20between%20them.\r\nPage 3 of 4\n\nAllow multiple readers to read simultaneously.\r\nGrant writers exclusive access to shared data.\r\nApply priority rules to avoid starvation.\r\nSleeping Barber Problem\r\nThis problem demonstrates process coordination. The Sleeping Barber Problem models a barber who sleeps\r\nwhen there are no customers and is awakened when a customer arrives and a chair is available. The difficulty lies\r\nin managing waiting chairs and customer arrivals correctly.\r\nSolution\r\nUse semaphores to manage customer arrival and barber availability.\r\nBarber sleeps when no customers are present.\r\nCustomers wait if chairs are available; otherwise, they leave.\r\nEnsures proper process coordination without deadlock.\r\nSource: https://www.geeksforgeeks.org/inter-process-communication-ipc/#:~:text=Inter%2Dprocess%20communication%20(IPC),of%20co%2\r\nDoperation%20between%20them.\r\nhttps://www.geeksforgeeks.org/inter-process-communication-ipc/#:~:text=Inter%2Dprocess%20communication%20(IPC),of%20co%2Doperation%20between%20them.\r\nPage 4 of 4",
	"extraction_quality": 1,
	"language": "EN",
	"sources": [
		"MITRE"
	],
	"origins": [
		"web"
	],
	"references": [
		"https://www.geeksforgeeks.org/inter-process-communication-ipc/#:~:text=Inter%2Dprocess%20communication%20(IPC),of%20co%2Doperation%20between%20them."
	],
	"report_names": [
		"#:~:text=Inter%2Dprocess%20communication%20(IPC),of%20co%2Doperation%20between%20them."
	],
	"threat_actors": [
		{
			"id": "d90307b6-14a9-4d0b-9156-89e453d6eb13",
			"created_at": "2022-10-25T16:07:23.773944Z",
			"updated_at": "2026-04-10T02:00:04.746188Z",
			"deleted_at": null,
			"main_name": "Lead",
			"aliases": [
				"Casper",
				"TG-3279"
			],
			"source_name": "ETDA:Lead",
			"tools": [
				"Agentemis",
				"BleDoor",
				"Cobalt Strike",
				"CobaltStrike",
				"RbDoor",
				"RibDoor",
				"Winnti",
				"cobeacon"
			],
			"source_id": "ETDA",
			"reports": null
		}
	],
	"ts_created_at": 1775439129,
	"ts_updated_at": 1775826769,
	"ts_creation_date": 0,
	"ts_modification_date": 0,
	"files": {
		"pdf": "https://archive.orkl.eu/5d27e832fac09a714eeaa0a3563177894bdd9fb8.pdf",
		"text": "https://archive.orkl.eu/5d27e832fac09a714eeaa0a3563177894bdd9fb8.txt",
		"img": "https://archive.orkl.eu/5d27e832fac09a714eeaa0a3563177894bdd9fb8.jpg"
	}
}