December 31, 2019

What is Cyber kill chain



Cyber kill chain
사이버 킬 체인

Kill Chain is a preemptive attack strategy proposed to defend Iraqi missiles in the Gulf War (1991).
킬 체인은 걸프전(1991)에서 이라크군의 미사일을 방어하기 위해 제시된 선제 공격형 방어 전략이다.

The term is generally means to detect missile launch signs and strike missile launcher in advance.
일반적으로는 발사 징후를 탐지하여 사전에 미사일 시설을 타격한다는 의미로 사용된다.

This is because it is technically easier than shooting down missiles that have already been launched.
이는 이미 발사된 미사일을 격추하는 것보다 기술적으로 수월하기 때문이다.

The key of this strategy is the concept of blocking an attack by breaking(kill) the intermediate process(chain) of enemy activity leading to an attack.
이 전략의 핵심은 적의 활동이 공격으로 이어지는 중간 과정을(chain) 끊어버림으로써(kill) 공격을 차단한다는 개념이다.

The first use of the word cyber kill chain was weapon company Lockheed Martin(2011).
사이버 킬 체인이란 단어를 최초 사용한 곳은 방위산업체 록히드 마틴(2011)이다.

Cyber Kill Chain is a defense strategy against cyber attacks and suggests each countermeasure according to the 7 stages of enemy APT attacks.
사이버 킬 체인은 사이버 공격에 대한 방어 전략이며, 적의 APT 공격의 7단계에 따른 각각의 대응 방법을 제시한다.

The key here is to prevent the final attack by taking appropriate steps at each stage.
여기에서의 핵심은 각 단계별 적절한 대응을 통해 최종적인 공격을 예방하는 것이다.

This does not include the meaning of preemptive strikes against attackers as in the kill chains used by the military.
이는 군에서 사용하는 킬 체인에서처럼 공격 주체에 대한 선제 타격의 의미는 포함되어 있지는 않다.

However, they have something in common in terms of proactive attack prevention.
그러나 사전 대응을 통한 공격 차단이라는 측면에서는 공통점이 있다.

The reason this strategy can defended is in the property of the attack.
이러한 전략으로 방어가 가능한 이유는 공격의 특성에 있다.

There are many steps in the attack, and the previous stage is required to move on to the next stage.
공격에는 단계가 있으며 이전 단계는 다음 단계로 진행하기 위해 필수적으로 요구되기 때문이다.

For example, in order to launch a missile, there are steps to enter the target's coordinates.
예를 들어 미사일을 발사하기 위해서는 목표물의 좌표를 입력해야 하는 단계가 있다.

When this process takes place, disturbing the enemy's information system causes malfunctions such as entering wrong coordinates, the attack can be fails.
이 과정이 이루어지는 시점에 적의 정보 체계를 교란하면 잘못된 좌표를 기입하게되는 등의 오작동이 유발되어 결국 공격에 실패하게 된다는 원리이다.

This strategy is more active than traditional action that only after an attack occurs, since the concept of "prevention" is included.
이러한 전략은 "예방"이라는 개념이 포함되기에 비로소 공격이 발생한 이후에야 급히 대응하는 전통적인 대응 방식보다 적극적이다.

Lockheed Martin's cyber kill chain concept presents seven steps leading up to an attack. If you interrupt any of the intermediate steps, the attack will fail.
록히드 마틴의 사이버 킬 체인 개념은 공격으로 귀결되기까지의 단계를 7가지로 제시하였으며 다음과 같다. 중간 과정 중 하나라도 끊으면 공격은 실패하게 된다.

1. Reconnaissance: Identify, investigate, and select attack targets.
정찰: 공격 목표 식별, 조사, 선정.
2. Weaponization: Select and prepare cyber weapons for intrusion.
무기화: 침투용 사이버 웨폰 선정, 준비.
3. Delivery: Deploy cyber weapon.
운반: 사이버 웨폰 배치.
4. Exploitation: Intrude the system through the use of cyber weapons.
취약점 공격: 사이버 웨폰 사용을 통한 시스템 침투.
5. Installation: Install malicious code on intruded systems.
설치: 침투한 시스템에 악성 코드 설치.
6. C&C(command & control): Build a remote control environment with the malicious code.
지휘통제: 악성 코드로 원격 제어 환경 구축.
7. Actions on objectives: Achieve goals such as information leakage and system destruction.
공격 전개: 정보 유출, 시스템 파괴 등의 목표 달성.

See the links below for how to respond to each step.
각 단계에 대한 대응 방법은 아래 링크를 참조한다.
https://www.lockheedmartin.com/content/dam/lockheed-martin/rms/documents/cyber/Gaining_the_Advantage_Cyber_Kill_Chain.pdf

October 22, 2019

What is Browser fingerprinting #1


How to track activity by identifying users via a browser.
브라우저를 매개로 사용자를 식별하여 활동을 추적하는 방법.

In many cases, cookie is used to track user activity, but browser fingerprinting can be used to track users without cookies.
많은 경우 쿠키를 통해 사용자 활동을 추적하지만, 브라우저 핑거프린팅을 이용하면 쿠키 없이도 추적할 수 있다.

Information can be collected includes:
수집 가능하다고 알려진 정보로는 아래와 같은 것들이 있다.

Language, location, operating system, browser type/version, resolution, search keyword, voice, web cam image, time zone, plugins, keyboard/mouse gestures, available fonts, GPU information, sites visited, etc.
사용 언어, 위치, 운영 체제, 브라우저 종류/버전, 해상도, 검색어, 목소리, 웹 캠 영상, 타임 존, 사용하는 플러그인, 키보드/마우스 동작, 가용한 폰트, GPU 정보, 방문했던 사이트 등

The collected information can be combined to identify each individual.
수집된 정보들을 조합하면 각 개인을 식별할 수 있다.

Browser fingerprinting information is rarely the same. There was a claim that one in every 280,000 was the same.
브라우저 핑거프린팅 정보가 동일한 경우는 드물다. 28만명당 1명꼴로 동일하다는 주장도 있었다.
https://panopticlick.eff.org/static/browser-uniqueness.pdf

Browser fingerprinting is typically used for the purpose of targeting advertising.
브라우저 핑거프린팅은 타게팅 광고를 목적으로 사용되는 것이 대표적이다.

One YouTuber did an experiment. When he launched a Chrome browser and mentioned a certain keyword several times, the related advertisements appeared.
어느 유튜버가 관련된 실험을 하기도 했었다. 크롬 브라우저를 띄운 상태에서 자연스럽게 특정 키워드를 여러 번 언급했더니 관련 광고가 나오더라는 것이다.
https://youtu.be/zBnDWSvaQ1I

It can be a little creepy for someone to intercept personal information, but it's usually harmless. But if someone has a bad heart, it can be misused, so be careful.
개인정보를 누군가 감청한다는 것이 조금 크리피할 수는 있지만 대체로 무해하다. 하지만 누군가 나쁜 마음을 먹으면 악용될 소지가 있으므로 주의가 요구된다.

October 07, 2019

What is the credential stuffing




크리덴셜 스터핑(Credential stuffing)

- 크리덴셜(Credential): Encrypted authentication information.
암호화된 인증 정보.

- 스터핑(Stuffing): Fill it up. Push. → Large amount of attempt.
채워 넣기. 밀어 넣기. → 다량의 시도.

크리덴셜 스터핑(Credential stuffing)
Submitting a large amount of credentials to the certification system. Mass login attempt. Brute Force.
인증 시스템에 크리덴셜을 다량으로 제출하는 것. 다량 로그인 시도. 브루트 포스.


[Process] 발생 과정
1. Inappropriate security habits of individuals: Use the same password on multiple sites, or reuse old passwords on other sites.
1. 개인의 부적절한 보안 습관: 여러 사이트에서 동일한 비밀번호를 사용하거나, 과거 사용하던 비밀번호를 다른 사이트에서 재활용한다.

2. Security issue occurs: Due to security vulnerabilities, personal information (credentials) of certain institutions are leaked and distributed on the black market.
2. 보안 이슈 발생: 보안 취약점으로 인해 특정 기관의 개인정보(크리덴셜)가 유출되며 암시장에서 유통된다.

3. Inappropriate security response of institution: Failure to detect credential stuffing attacks or lack of capability or manpower may be limited timely response.
3. 기관의 부적절한 보안 대응: 크리덴셜 스터핑 공격을 탐지하지 못하거나, 능력이나 인력 부족 등으로 적시 적절한 대응이 제한될 수 있다.

4. Account hijacked by credential stuffing attack:
Although the success rate is low, it is reported that hijacking hundreds of thousands of accounts is possible if attempted at various sites using tens of millions of credentials. There is also a popular attack tool for this.
4. 크리덴션 스터핑 공격으로 계정 탈취: 성공률은 낮지만, 수백-수천만 개의 크리덴셜로 다양한 사이트에서 시도하다 보면 수십만 개의 계정을 탈취하는 것이 확률상 불가능하지 않은 것으로 보고되고 있다. 이를 위한 유명한 공격 툴도 존재한다
* SentryMBA, Vertex Cracker, Account Hitman etc.

5. Damages: Various threats such as public threats to social media, account deletion, account sales, opening of fake accounts, theft of photos, and withdrawal of funds can occur.
5. 피해 발생: SNS 등에 공개 협박을 받거나, 계정 삭제, 계정 판매, 대포통장 개설, 사진 도용, 자금 인출 등의 다양한 피해가 발생할 수 있다.

September 16, 2019

What is Kill switch


킬 스위치(Kill switch)

Switch that can disable certain functions.
특정 기능을 중지시킬 수 있는 스위치.

The expression "kill switch is enabled" is used.
"킬 스위치를 활성화한다"는 표현을 사용한다.

If it is enabled, all or part of its functions are stopped. It becomes froze up.
활성화 시 전체 또는 일부 기능이 중지된다. 먹통이 된다.

Kill switches can be applied in a variety of cases.
킬 스위치는 다양한 경우에 적용될 수 있다.

When applied to a smartphone, it means that the function is remotely locked to prevent using from others if lost.
스마트폰에 적용되는 경우, 분실 시 타인이 사용하지 못하도록, 원격으로 기능을 잠근다는 것을 의미한다.

Even if a thief steals someone else's smartphone, the thief will not be able to resell it. So, there is theft prevention effect.
타인의 스마트폰을 탈취하여도 재 판매할 수 없게 되므로, 도난 방지 효과가 생긴다.

When applied to malware, it means disabling its spread or infection functions.
악성코드에 적용되는 경우, 확산이나 감염 기능을 중지시킨다는 것을 의미한다.

The hacker may have planted to stop the attack at the point it wants, but it could be exploited.
해커가 원하는 시점에 공격을 종료하고자 심어 두었겠지만 역 이용될 수도 있다.

When applied to a VPN, at the time when the VPN is disconnected due to deterioration of the network situation, it means to disconnect all current communication(stop the communication function).
VPN에 적용되는 경우, 네트워크 상황 악화 등으로 부득이 VPN 연결이 해제되는 시점에, 현재 통신 중인 모든 연결을 해제(통신 기능을 중지)하는 것을 의미한다.

Disconnecting a VPN at an unwanted time means that personal privacy can be revealed, so it's automatically disconnected to prevent this.
원치 않는 시점에 VPN 연결이 해제된다는 것은, 개인의 사생활이 드러날 수 있다는 것을 의미하기에, 이를 방지하고자 자동으로 연결을 해제하는 것이다.

So, there is the effect of enhancing privacy.
이를 통해, 개인정보보호가 강화되는 효과가 생긴다.

Recently, it was a opinion that network equipment provided in certain countries are equipped with kill switches.
최근엔 특정 국가에서 제공하는 네트워크 장비에 킬 스위치가 장착되어 유통된다는 설도 있었다.

If it is true, a country's network may be paralyzed in case of emergency.
사실이라면 유사시 어느 한 국가의 네트워크를 마비시킬 수도 있을 것이다.

July 29, 2019

Popular LotL attack tools for hackers



해커에게 인기 있는 LotL 공격 툴

LotL 공격 개요

LotL Attack Overview

An attack technique that bypasses various defense systems using normal tools rather than the inherent tools that leave a unique trace.

특유의 흔적이 남는 고유의 툴보다, 정상 툴을 이용하여 다양한 방어 시스템을 우회하는 공격 기법.


메타스플로잇(Metasploit) / 코발트 스트라이크(Cobalt strike)

It is a popular penetration testing platform used by the security teams of each company.

각 기업의 보안 팀에서 사용되는, 유명한 모의해킹 목적의 플랫폼이다.

It is used disguising a penetration testing but is exploited by real attacks.

모의해킹을 가장하여 실제 공격에 악용된다.


파워쉘(PowerShell)

Command interpreter such as CMD or shell.

CMD나 쉘과 같은 명령어 인터프리터.

It has the advantage of being able to run on Windows as well as Linux (installation required).

윈도우 뿐만 아니라, 리눅스에서도 실행될 수 있다는(설치 필요) 장점이 있다.

There is a PowerSploit, which is a collection of tools developed solely with PowerShell.

파워쉘로만 개발된 툴을 모아놓은 파워스플로잇(PowerSploit)이 존재할 정도이다.


윈도우 시스인터널(Windows Sysinternal)

It is a toolkit for Windows based utilities.

윈도우 기본 유틸리티들을 모아놓은 툴킷.

Remote commands as well as network status and process control can be performed.

네트워크 현황이나 프로세스 제어뿐만 아니라 원격 명령도 수행 가능하다.


VNC(Virtual Network Computing)

RFB protocol based remote access tool.

RFB 프로토콜 기반의 원격 접속 툴.

There is Hidden Virtual Network Computing (HVNC), which is equipped with additional functions such as executing commands with the privileges of the system user while remote accessing, but it is classified as RAT malicious code.

원격 접속 간 시스템 사용자의 권한으로 명령어를 실행 시키는 등의 추가 기능이 탑재된, HVNC(Hidden Virtual Network Computing)라는 것도 있는데, 이는 RAT 악성코드로 분류되기도 한다.


팀뷰어(TeamViewer)

Famous remote access tool.

유명한 원격 접속 툴.

Like any remote access tool, it is used for purpose of dominating system.

어느 원격 접속 툴과 마찬가지로 시스템 장악 목적으로 사용된다.

In general, the TeamViewer account is stolen via brute force.

일반적으로 브루트 포스를 통해 팀뷰어 계정이 탈취된다.

System ports such as 80 or 443 can also be used, and damage cases such as being abused as a backdoor frequently occur.

80이나 443 같은 시스템 포트도 사용할 수 있으며, 백도어로 악용되는 등의 피해사례가 자주 발생한다.


LOLBAS(Living Off the Land Binaries and Scripts)

A project initiated by security experts to identify the normal tools that can be exploited for LotL attacks.

보안 전문가들에 의해 시작된, LotL 공격에 악용될 수 있는 정상 툴을 식별하는 프로젝트.

It includes tools that include functions such as code execution, compilation, download/upload, log collection and security system bypass.

코드 실행, 컴파일, 다운로드/업로드, 로그 등의 정보 수집, 보안 시스템 우회 등의 기능이 포함된 툴을 대상으로 한다.

It is also a certified tool from Microsoft or a downloadable tool.

또한 MS로부터 인증된 툴이거나 다운로드 받을 수 있는 툴이라는 특징이 있다.

July 22, 2019

What is LotL(Living-off-the Land) attack



LotL(Living-off-the Land) attack
자급자족식 공격.

Attack tactics that utilize software owned by the victim.

희생자가 보유한 소프트웨어를 활용하는 공격 전술.

Although it is a recently highlighted attack way, the concept has existed for about 20 years.

최근 부각되고 있는 공격 방식이지만, 개념은 약 20여 년 전부터 존재했다.

As the protection level of security solutions is improved, attacks using software that can pass through monitoring or are not monitored are attracting attention.

보안 솔루션의 보호 능력이 향상됨에 따라, 감시를 통과할 수 있거나 감시 대상이 아닌 소프트웨어를 이용한 공격 방식이 주목받고 있는 것이다.

Even if the Windows operating system installed, hundreds of legitimate tools also are installed, including CMD and PowerShell.

윈도우 운영체제만 설치해도, CMD, 파워쉘을 포함하여 크고 작은 수백개의 합법적 툴이 존재한다.

Alternatively, there may be software installed by the user but with vulnerability.

또는, 사용자가 설치하였지만 취약점이 심어져 있는 소프트웨어가 존재할 가능성이 있다.

Utilization of normal tools falls into the normal activity category of the system.

정상적인 툴을 활용하는 것은 시스템의 정상 활동 범주에 속하게 된다.

As a result, it has several advantages that are lacking in previous attack methods.

이에 따라, 기존의 공격 방식에서는 결여된, 몇 가지 이점을 갖추게 된다.

1. Using normal tools increases the chances of bypassing various protection measures.

1. 정상 툴을 이용하므로 다양한 보호 대책을 우회할 가능성이 증가한다.

2. The probability of identifying attacker is decreased.

2. 공격자가 누구인지 식별될 확률이 감소한다.

In contrast to the use of the tool itself. the specific behavior pattern of the tool remains in the system.

자체적인 툴 사용 시, 해당 툴 특유의 동작 패턴이 시스템에 남는 것과는 대조적이다.

3. The attack preparation time is shortened.

3. 공격 준비 시간이 단축된다.

This is because there is less or no time for identifying and exploit the vulnerability.

취약점 식별 및 활용에 소요되는 시간이 없거나 감소하기 때문이다.


June 28, 2019

What is APT attack


APT attack.
APT 공격.

Advanced Persistent Threat.
지능형 지속 위협.

Systematic cyber attacks based on strategy / tactics rather than repetitive or event-based attacks.

반복이나 이벤트식의 각개 공격이 아닌, 전략/전술 기반의 체계적인 사이버 공격.

In order to achieve an effective goal, the contents of each step are distinguished. It is similar to an offensive military operation.

효과적인 목표 달성을 위하여 각 단계별 수행 내용이 구분되며, 공세적 군사 작전과 유사하다.

The lifecycle of APT Attack.
APT 공격의 라이프사이클

Target Analysis → Securing access road → Attack → Evaluate/supplement
표적 분석 → 접근로 확보 → 공격 → 평가/보완

Target Analysis
Plan what attacks will be performed on which target and step.

표적 분석
어떤 표적을 대상으로 어떤 단계에 어떤 공격을 수행할지 계획한다.

Securing access road
Secure and maintain an access road for penetratation.

접근로 확보
침투를 위한 접근로를 확보하며 이를 유지한다.

Attack.
Penetrate through secured access road and carry out a full-out cyber attack to achieve the goal.

공격
확보한 접근로를 통해 침투하여 목표 달성을 위한 본격적인 사이버 공격을 수행한다.

Evaluate/supplement
Evaluate the process and results and supplement the defects, for the more effective APT attacks in the future.

평가/보완
향후 더욱 효과적인 APT 공격을 위해 과정과 결과를 평가하고 미비점을 보완한다.

An attacker generally secures an access road in such a way as to take control of individual systems such as PC or IoT devices exposed to the outside, rather than directly penetrating server-centric centralized and layered defense systems.

공격자는 일반적으로, 서버 중심의 중앙화 및 계층화된 방어 시스템을 직접 침투하는 것보다는, 외부에 노출된 PC나 IOT 기기 등의 각개 시스템을 장악하는 방식으로 접근로를 확보한다.

The access road is sometimes secured through direct hacking, but the way of distributing malicious e-mail or spam messages is often used. It becomes more tricky by impersonating government agencies etc.

접근로 확보는 직접적인 해킹을 통해 달성하는 경우도 있으나, 악성 메일이나 스팸 메시지 등을 유포하는 방식이 자주 사용되는데, 정부기관을 사칭하는 등 그 방법이 점점 교묘해지고 있다.

For example, if employee A responds to an email asking for opening an attachment related the business, this would infect the PC with malicious code, and an attacker who penetrated the central server via that PC would spill out the privacy information. These scenarios are now too clichéd.

예를 들어, 직원 A는 업무와 관련하여 첨부 파일 열람을 요구하는 이메일에 응했을 뿐이지만, 이로 인해 PC가 악성코드에 감염되고, 해당 PC를 통해 중앙 서버에 침투한 공격자가 3개월 뒤 고객정보를 유출하는 시나리오는 이제는 너무 진부하다.

June 17, 2019

Backgrounds and differences in the birth of modules and components


These two terms are often mentioned in the relevant industry, but few know exactly.

이 두 용어는 관련 업계에서 자주 언급되지만 정확히 아는 사람은 드물다.

In the 1970s, software complexity emerged.

1970년대에 들어서면서 소프트웨어의 복잡도가 대두되었다.

As the software code becomes larger, it becomes more difficult to manage.

소프트웨어 코드가 방대해짐에 따라 관리하기가 어려워진 것이다.

Various attempts have been made to properly control this, and reached the conclusion that the code should be structured.

이를 적절히 통제하고자 다양한 시도 있었고, 그 결과 코드의 구조화라는 결론에 이르게 된다.

In other words, the code should be arranged according to the rule.

쉽게 말하면 코드를 기준에 따라 정리정돈 한다는 것이다.

In this background, Module and Component that are code structuring methods have emerged.

이러한 배경에서 모듈과 컴포넌트라는 코드 구조화 방식이 탄생했다.

Conceptual scope: Component ⊂ module

개념상의 범위: 컴포넌트 ⊂ 모듈

Module basically refers to a "collection of code that can be reused(recycled)".

모듈은 기본적으로, "재사용(재활용)이 가능한 코드의 모음"을 가리킨다.

It can be called module, if it shows a structural view that can be reused.

재사용이 가능할 정도의 구조적인 모습을 보이면 모듈이라고 할 수 있다.

Likewise, components is categorized into module and also can be reused.

마찬가지로 컴포넌트도 모듈에 범주에 들어가며 재사용될 수 있다.

The main distinction between modules and components is the degree of "independence".

모듈과 컴포넌트의 구분 짓는 주요한 차이는 "독립성"의 정도이다.

Component has the interface for executing

컴포넌트는 구동시키기 위한 인터페이스가 존재한다.

Having an interface means that if you only know how to use the interface, you can use it without having to open or modify it.

인터페이스가 있다는 것은, 인터페이스의 사용법만 숙지한다면 내부를 열어보거나 수정하지 않아도 사용할 수 있다는 의미이며, 이를 보고 "독립성"이 강하다고 말한다.

Modules in non-component areas may not be available outside of the project area (because of the difficulty of using) because the interfaces are missing or weak.

컴포넌트가 아닌 영역의 모듈은 인터페이스가 없거나 미약하여, 해당 프로젝트 외부의 영역 외부에서는 (사용법이 까다롭기에) 활용하지 못하는 경우도 있다.

People usually think of small and various components being used in large modules, but not necessarily.

보통은 커다란 모듈에 작고 다양한 컴포넌트들이 사용되는 모습을 그리곤 하지만, 반드시 그래야 하는 하는 아니다.

The inside of a component can be divided into several modules.

하나의 컴포넌트의 내부는 여러 모듈로 구분될 수도 있다.

If you develop code that is neatly structured rather than rag-like, it becomes a component consisting of modules.

코드를 누더기식으로 작성하는 것이 아닌, 깔끔하게 구조를 갖추어 개발한다면, 그것이 모듈로 이루어진 컴포넌트가 되는 것이다.

Therefore, the size of the code can not distinguish the two, and the conceptual difference must be considered.

그러므로 코드의 규모로 이 둘을 구분할 수는 없으며, 개념상의 차이를 고려해야 한다.



June 14, 2019

The local/global environment variable in Linux



Environment variable.
A variable that stores settings related to system operation.

환경 변수
시스템 동작과 관련된 설정 값을 저장하는 변수.

Local environment variable.
The variable available in the current shell only.

지역(local) 환경 변수
현재 쉘에서만 사용 가능한 변수

$ TEST1=value1
$ set | grep TEST1

Global environment variable.
The variable available in the current shell and sub shell.

전역(global) 환경 변수
현재 쉘과 서브 쉘에서 사용 가능한 변수

$ export TEST2=value2
$ set | grep TEST2

Remove Environment variable.
환경 변수 제거.

$ unset TEST1

Characteristic
특징

1. The local/global environment variable that you set is only available in the current session. If you want to use it at the next login, you can register it in the configuration file.

1. 설정한 지역/전역 환경 변수는 현재 세션에서만 사용 가능하다. 만약 다음 로그인 시에도 사용하고 싶다면 설정 파일에 등록하면 된다.

e.g. To reflect all accounts in the system, register in /etc/profile.

e.g. 해당 시스템 내 모든 계정에 반영 하려면 /etc/profile에 등록한다.

2. The environment variables set in the child process can not affect the parent process. When using global variables, the parent can affect the child.

2. 자식 프로세스에서 설정한 환경 변수는 부모 프로세스에 영향을 줄 수 없다. 전역 변수 사용 시 부모가 자식에게 영향을 줄 수 있다.

$ bash
$ BBB=1
$ export CCC=1

$ exit
$ set | grep BBB; set | grep CCC;
$ env | grep BBB; env | grep CCC;
$

3. When setting the global environment variable, it is also reflected in the local environment variable(overwrite).

3. 전역 환경 변수 설정 시, 지역 환경 변수에도 반영된다(덮어쓰기).

$ BB=1
$ set | grep BB; env | grep BB;
BB=1

$ export BB=2
$ set | grep BB; env | grep BB;
BB=2
BB=2

4. When setting the local environment variable, all global environment variables with the same name are reflected (overwrite).

4. 지역 환경 변수 설정 시, 전역 환경 변수에 동일한 이름이 있다면 모두 반영된다(덮어쓰기).

$ export BB=2
$ set | grep BB; env | grep BB;
BB=2
BB=2

$ BB=3
$ set | grep BB; env | grep BB;
BB=3
BB=3

5. When removing environment variables, global/local environment variables are removed together.

5. 환경 변수 제거 시 전역/지역 환경 변수가 함께 제거된다.

$ set | grep BB; env | grep BB;
BB=3
BB=3

$ unset BB
$ set | grep BB; env | grep BB;
$



June 10, 2019

The reason why the SHA-1 hash value is 20 bytes and 40 bytes at the same time


Hash value.
Information that is unique to each piece of data. Digital fingerprint.

해시(Hash)값.
데이터마다 고유하게 가지고 있는 정보. 디지털 지문.

The hash value can be checked through various hash algorithms.
CRC, MD5, SHA-1, SHA-256 etc.

해시 값은 다양한 해시 알고리즘을 통해 확인할 수 있다.
CRC, MD5, SHA-1, SHA-256 등

Each hash value has a unique length according to the algorithm.
It is not related to the amount of original data.

그리고 각 해시값은 알고리즘에 따라 고유한 길이를 가진다.
원본 데이터의 분량과는 관계가 없다.

The length of the each algorithm hash value.

알고리즘별 해시값의 길이.

CRC40
$ echo 1 | cksum
4219530715

40bit = 5Bytes = 10Bytes(??)

It is 5Bytes in hexadecimal basis but 10Bytes in string basis.

16진수 기준으로는 5Bytes지만, 문자열 기준으로는 10Bytes이다.

(ASCII)character express 1Bytes per character, but hexadecimal express 0~255 value as 1Bytes.

(ASCII)문자열 기준으로는 1글자당 1Bytes지만, 16진수 기준으로는 0~255 수치를 1Bytes로 표현할 수 있기 때문.

Assuming that there is a value of FF, it is 2Bytes because it is 2 characters. However, since FF is a decimal value of 255, it can be represented as 1 byte in hexadecimal basis. That is, the length is two times different according to the standard.

FF라는 값이 있다고 가정하면, 문자열 기준으로는 2글자이기에 2Bytes다. 그러나 FF는 10진수로 255라는 값이므로 16진수 기준으로는 1Byte로 표현할 수 있다. 즉, 기준에 따라 길이가 2배 차이난다.

$ echo 1 | cksum
4219530715 → 42 19 53 07 15
40bit = 5Bytes(16진수 기준) = 10Bytes(문자열 기준)

MD5
128bit = 16Bytes = 32Bytes(문자열)
$ echo 1 | md5sum
b026324c6904b2a9cb4b88d6d61c81d1

SHA-1
160bit = 20Bytes = 40Bytes(문자열)
$ echo 1 | sha1sum
e5fa44f2b31c1fb553b6021e7360d07d5d91ff5e

SHA-256
256bit = 32Bytes = 64Bytes(문자열)
$ echo 1 | sha256sum
4355a46b19d348dc2f57c046f8ef63d4538ebb936000f3c9ee954a27460dd865

SHA-384
384bit = 48Bytes = 96Bytes(문자열)
$ echo 1 | sha384sum
d654902b550e334bb6898d5c4ab8ebe1aedc6c85368eafe28e0f89b62a74a23e1ed20abbc10c02ce321266384d444717

SHA-512
512bit = 64Bytes = 128Bytes(문자열)
$ echo 1 | sha256sum
3abb6677af34ac57c0ca5828fd94f9d886c26ce59a8ce60ecf6778079423dccff1d6f19cb655805d56098e6d38a1a710dee59523eed7511e5a9e4b8ccb3a4686

June 07, 2019

What is CORS



Cross-origin
교차 출처

For example, YouTube video sharing is a cross-source.

예를 들어, 유튜브 영상 공유하기는 교차 출처에 해당된다.

Because it will request the video data of the YouTube server from the shared location.

공유된 위치에서 유튜브 서버의 영상 자료를 요청하게되기 때문.

Conversely, viewing YouTube videos on YouTube sites is the Same-origin.

반대로, 유튜브 사이트에서 유튜브 영상을 보는 것은 동일 출처에 해당한다.



CORS(Cross-Origin Resource Sharing)
교차 출처 자원 공유

Mechanism used to verify the safety of a resource request from a other domain not original domain(Cross-origin).

원래의 도메인이 아닌 다른 도메인(교차 출처)의 자원 요청 시, 안전성을 확인하기 위해, 사용되는 메커니즘.

If CORS is enabled, data from other domains can be retrieved.

CORS가 허용(enabled)된 경우, 타 도메인의 자료를 불러올 수 있다.

You can import data (cross-origin) from other domains without restriction by using <img>, <src> tags, etc. However, there is a case importing from only the same domain(Same-origin).

<img>, <src> 태그 등을 이용하면 제한 없이 타 도메인의 자료(교차 출처, Cross-Origin)를 가져올 수 있지만, 보안 등의 이유로 동일 도메인의 자료(동일 출처, Same-Origin)만 허용된 경우가 있다.

When applied to a Same-Origin policy for security reasons, CORS must be allowed to use cross-origin data.

보안 등의 이유로 동일 출처 정책(Same-Origin policy)에 적용받는 경우 CORS가 허용되어야만 교차 출처의 자료를 사용할 수 있다.



A representative example: XMLHttpRequest.

대표적 예시: XMLHttpRequest.

XMLHttpRequest can only use data from the same domain because the same origin policy applied.

XMLHttpRequest는 동일 출처 정책(Same-Origin policy)이 적용되어 동일한 도메인의 자료만 사용할 수 있다.

However, if CORS is enabled on a server, it can use the requested data even if the server is a different domain.

하지만 CORS가 허용(enabled)된 서버가 있다면, 그 서버가 다른 도메인이어도 요청한 자료를 사용할 수 있다.




There are three types of CORS, and the method is determined according to the content of the request message(header).

CORS는 크게 3가지 유형으로 구분되며, 요청 메시지(헤더)의 내용에 따라 그 방식이 결정된다.

1. Simple request
Adding a header entry "Origin" to the request message for recording which domain sent the request.

1. 간단한 요청(simple)
요청 메시지에 "Origin" 이라는 헤더 항목을 추가하여 어느 도메인에서 발송된 요청인지 기록하는 방식.

The "ACAO" header field in the response message confirms whether CORS is allowed.

응답 메시지에 "ACAO" 헤더 항목을 통해 CORS 허용 여부를 확인할 수 있다.

For example, if the response message contains the ACAO header entry "Access-Control-Allow-Origin: http://a.com", only "a.com" is allowed in CORS.

예를 들어, 응답 메시지에 "Access-Control-Allow-Origin: http://a.com"이란 ACAO 헤더 항목이 포함되었다면 "a.com"만 CORS가 허용된다.

2. Preflight request.
It is the method of sending a preflight to verify that a response to a cross-origin request is possible.

2. 사전 요청(preflight)
교차 출처 요청에 대한 응답이 가능한지를 확인하기 위해, 사전 요청(preflight)을 보내어 확인하는 방식.

3. Credential request.
A method of transmitting authentication information on request.

3. 인증 요청(Credential)
요청 시 인증 정보를 담아 전송하는 방식.

Only authenticated domains are allowed in CORS.

인증된 도메인만이 CORS가 허용된다.



June 03, 2019

Five differences between soft links and hard links.



Link: A word used to refer to a shortcut file in Linux.

링크: 리눅스에서 바로가기 파일을 호칭할 때 사용하는 단어.

There are two types of links.

링크는 크게 두 종류로 구분된다.

소프트 링크(Soft link) = 심볼릭 링크(Symbolic) - S
하드 링크(Hard link) - H


1. I-node

(S) It does not share the i-node of the original file(It use new i-node).

(S) 원본 파일과 I-node를 공유하지 않는다.

(H) It shares i-node of the original file

(H) 원본 파일과 I-node를 공유한다.

* I-node: The information(data structure) to distinguish each file and has a unique number.

* I-node(아이노드): 각 파일을 구분하는 기준이 되는 정보(자료구조)이며, 고유한 번호를 갖는다.


2. Create.  생성.

(S) It is possible to create a different file system

(S) 서로 다른 파일 시스템에 생성 가능.

(H) It is impossible to create a different file system.

(H) 서로 다른 파일 시스템에 생성 불가능.

* File system: How to manage data on disk.

* File system(파일 시스템): 디스크 내 데이터 관리 방식.


3. Work.  동작.

(S) It doesn't work if original file is deleted.

(S) 원본 파일 제거 시 동작 불가.

(H) It works even if original file is deleted.

(H) 원본 파일 제거 시에도 동작 가능.


4. The number of links.  링크 개수.

(S) It isn't reflected in the number of links that can be checked at "ls -al".

(S) "ls -al"로 확인 시 링크 개수에 반영되지 않음.

(H) It is reflected in the number of links that can be checked at "ls -al".

(H) "ls -al"로 확인 시 링크 개수에 반영됨.


5. File type.  파일 타입.

(S) It is recorded as the link file type that can be checked in "ls -al".

"ls -al"로 확인 시 파일 타입이 링크 타입으로 기록됨.

(H) It isn't recorded as the link file type that can be checked in "ls -al".

"ls -al"로 확인 시 파일 타입이 링크 타입으로 기록되지 않음(일반 파일).


It is important to consider whether each file is a separate file with different I-nodes.

각 파일이 서로 다른 I-node를 가진 별도의 파일인지 아닌지의 여부를 고려하는 것이 핵심.

May 31, 2019

What is CGI and CGI program


CGI(Common Gateway Interface)

A standard (technology) for dynamically sending and receiving data between "Web server ↔ CGI programs".
"웹 서버 ↔ CGI 프로그램" 간 데이터를 동적으로 주고받기 위한 표준(기술).

CGI program = web application
The CGI applied program that running on the server.
It can be implemented in various server-side languages such as ASP, PHP, JSP, and Perl.
It serves to provide a dynamic page to the client(browser).

CGI 프로그램 = 웹 애플리케이션
서버에서 실행되는, CGI가 적용된 프로그램.
ASP, PHP, JSP, Perl 등 다양한 서버 측 언어로 구현이 가능하다.
클라이언트(브라우저)의 요청에 동적 페이지를 제공하는 역할을 한다.

dynamic page
Pages that are provided to clients by creating a web page(HTML file) in real time considering the situation, even when requested to the same web page.

동적 페이지.
동일한 웹 페이지에 접속하더라도, 상황을 고려하여 실시간으로 웹 페이지(HTML 파일)를 만들어 클라이언트에게 제공되는 페이지.

Database browsing, login, etc. can be implemented by dynamic pages.

데이터베이스 열람, 로그인 등은 동적 페이지에 의해 구현이 가능하다.

More specifically, the CGI program is run by the Web Application Server(WAS), not the Web server.

보다 세부적으로 말하자면, CGI 프로그램은 웹 서버(Web Server)가 아니라 WAS(Web Application Server)에 의해 실행된다.

When a client makes a request, at first, web server checks its contents. If the requested data is a static page, it is handled directly, but if it is a dynamic page, the request is handed to WAS. At this point, WAS runs the CGI program and passes the results to the web server.

클라이언트의 요청이 있을 경우, 최초 웹 서버가 그 내용을 확인한다. 요청한 자료가 정적 페이지라면 직접 처리하지만, 동적 페이지라면 WAS에게 처리하도록 요청을 넘긴다. 이때 WAS는 CGI 프로그램을 실행하며, 그 결과는 웹 서버로 넘긴다.

May 27, 2019

What is Crontab


cronatab file.
A crontab file is a file that is processed by the cron daemon and defines a list of tasks to be performed on a regular basis.

cronatab 파일.
crontab 파일은 cron 데몬에 의해 처리되는 파일이며, 정기적으로 수행해야할 작업 목록을 정의한다.

crontab commands.
crontab 관련 명령어.

$ crontab -e flag04
Edit crontab file of flag04 account.
flag04 계정의 crontab 파일을 수정.

$ crontab -l flag04
List the contents of the crontab file for the flag04 account.
flag04 계정의 crontab 파일을 열람.

$ crontab -l
List the contents of the crontab file for my account.
자신의 crontab 파일을 열람.

$ crontab -r
Remove the crontab file for my account.
자신의 crontab 파일을 제거.

How to read the contents of a crontab file
crontab 파일의 내용 읽는 방법

The total fields are separated into six parts.
minute, hour, day, month, day of week, task

총 6개의 필드로 구분
분, 시, 일, 월, 요일, 작업

e.g 1.
0 4 * * * /tmp/task1 arg1 arg2
→Runs task1 at 4 am every day, including arg1 and arg2 arguments.
→매일 새벽 4시 정각에, arg1, arg2 아규먼트를 포함하여 task1을 실행한다.

*/5 * * * * /tmp/task2
→Run task2 every 5 minutes.
→매 5분마다 task2를 실행한다.

10 16 * * 1-4 /tmp/task3
10 16 * * 5-7 /tmp/task4
→From Monday to Thursday, at 16:10, run task3,
→From Friday to Sunday, at 16:10, run task4,
→월~목요일, 16시 10분엔 task3을 수행하고,
→금~일요일, 16시 10분엔 task4를 수행한다.


May 24, 2019

What is the public key encryption


Just as facility is protected by a lock, when you protect your data, encrypt is required, and then the cipher key is needed.

자물쇠로 시설을 보호하듯이, 데이터를 보호할 때는 암호화를 하며, 이때 암호 키가 필요하다.

Public key encryption is the encryption method that can communicate securely even when a cipher key is disclosed.

공개 키 암호는 암호 키를 공개해도 안전하게 통신할 수 있는 암호화 방식이다.

This disclosed key is called the public key and is used for encryption. It is open to anyone.

이렇게 공개된 키는 공개 키라고 부르며, 암호화 시점에 사용된다. 누구에게나 공개된다.

There is a key that matches this public key, which is called a private key and is used for decryption. This key has only one person.

그리고 이 공개 키에 매칭되는 키가 있는데, 비밀 키라고 부르며 해독(복호화) 시 사용된다. 이 키는 한 명만 가지고 있다.

When it thought as a lock, it is specially designed to have a key for locking purpose and a key for opening purpose.

자물쇠로 치면, 특수하게 설계되어, 잠금 목적의 키와 개방 목적의 키가 따로 존재하는 것과 같다.

For this reason, public key encryption is also referred to as asymmetric encryption.

이 때문에 공개 키 암호는 비대칭 암호라고 불리기도 한다.

In general, Its security is superior to symmetric key encryption with a single cipher key, but performance is poor.

일반적으로 보안성은 암호 키가 1개인, 대칭 키 암호 방식보다 우수하나 성능은 떨어진다.

On the contrary, there is the case where encryption is performed using a private key, which is the key possessed by only one person.

하지만 반대로, 한 명만 보유하는 암호 키인 비밀 키로 암호화하는 경우도 있다.

This is for use in authentication, Since there is only one private key that matches the public key, encryption with a private key implies that the creator of the ciphertext can be identified.

이는 인증에 활용하기 위해서인데, 공개 키와 매칭되는 비밀 키는 한 명만 가지고 있으므로, 비밀 키로 암호화를 한다는 것은, 해당 암호문을 만든 자를 식별할 수도 있다는 의미를 갖는다.

Therefore, if the data to be transmitted is protected by encrypting with the (opponent's) public key and the sender's information is encrypted with the (own) private key and transmitted, the data is protected, and the source of the data also can be clarified(authenticated).

그래서 전송할 데이터는 (상대의) 공개 키로 암호화하여 보호하고, 전송자의 이름은 (본인의) 개인 키로 암호화하여 전송하면, 데이터도 보호하고, 데이터의 출처도 명확(인증)해진다.

It is expressed as a signature, and it is the basis of a public certificate technique that everyone hates.

이것을 서명한다고 표현하며, 모두가 싫어하는 공인인증서 기술의 기초가 된다.

May 20, 2019

Archive vs Compression. Same but different



Archive: store. collect.
Compress: Press down. summarize.

아카이브(Archive): 보관하다. 수집하다.
압축(Compress): 누르다. 요약하다.

Common point: Collect one or more files. → You can bundle and store related data.

공통점: 하나 이상의 파일을 모아둔다. → 관련 있는 데이터들을 묶어 보관 및 전송 할 수 있다.

Different point: The archive does not compress the contents. That is, the file size does not decrease.

차이점: 아카이브는 내용을 압축하지 않는다. 즉, 파일 크기가 줄어들지 않는다.

The archive file can be compressed, but not necessarily compressed.

아카이브 파일을 압축할 수는 있지만, 반드시 압축해야 하는 것은 아니다.

Compression is divided into lossy compression and lossless compression according to the method.

압축은 그 방식에 따라, 손실 압축과 무손실 압축으로 구분된다.

lossy compression: How data is compressed by removing the original data.
lossless compression: How data is compressed by keeping the original data.

손실 압축: 원본 데이터를 제거하여 데이터를 압축하는 방식.
무손실 압축: 원본 데이터를 유지하며 데이터를 압축하는 방식.

Compression can be thought the general compression combined through a compression program, but in fact more often used in video/audio/images.

압축이라고 하면 압축 프로그램을 통해 합쳐진 일반 압축이 떠오르지만, 사실 영상/오디오/이미지에서 더 자주 사용된다.

For example, the lossy compression format includes mp3, jpeg, mpeg(H.264), and the lossless compression format includes such as gif and png.

예를 들어, 손실 압축 포맷에는 mp3, jpeg, mpeg(H.264) 등이 있고, 무손실 압축 포맷에는 gif, png 등이 있다.

Lossy compression is a method that removes parts that humans can not perceive (such as frequency bands that humans can not hear), so it is inappropriate for data archiving purposes, but it may be suitable for video etc. that can be partially lost.

손실 압축은 인간이 인지하지 못하는 부분(인간이 못 듣는 주파수 대역 등)을 제거하는 방식이기에, 데이터 보관 용도로는 부적합하지만, 반대로 일부를 손실해도 괜찮은 영상 등의 경우에는 적합할 수 있다.

Famous file formats
유명 파일 형식

Archive
아카이브
.tar
.jar

General compression
일반 압축
.z
.Z
.gz
.zip
.bz2
.rar
.7z

May 17, 2019

What is Caesar cipher


It is the cipher algorithm used by the Roman general Gaius Julius Caesar to communicate with the allied forces around 100 BC.

기원전 100년경, 로마의 장군 가이우스 율리우스 시저(Gaius Julius Caesar)가 동맹군들과의 소통을 목적으로 사용했던 암호 알고리즘.

It is a cipher algorithm that moves a certain distance based on alphabetical order and substitutes it with another alphabet.

알파벳 순서를 기준으로 일정 거리만큼 이동시켜 다른 알파벳으로 치환하는 방식의 암호 알고리즘.

A cryptographic key is required when creating a cipher text. In Caesar's cipher, the cipher key is the distance moved.

암호문을 만들 때는 암호키가 필요하다. 카이사르 암호에서 암호키는 이동한 거리이다.

If the encryption key is +3, B can be replaced by E.

암호키가 +3이라면, B는 E로 치환될 수 있다.

If the encryption key is 3, it is called ROT3(Rotate by 3). In general, ROT13 is frequently mentioned by convention.

만약 암호키가 3이라면, ROT3(Rotate by 3)이라고 불리기도 한다. 일반적으로 ROT13이 관례적으로 자주 언급된다.

vulnerably and unusually, cipher key appears in the cipher algorithm name.

취약하면서도 특이하게, 암호키가 암호 알고리즘 이름에 나타난다.

The English alphabet consists of 26 characters from a to z, so you can restore the ciphertext if you try 26 times while changing the key.

영어 알파벳의 경우, a부터 z까지 26자로 구성되어 있기에, 키를 바꾸어가며 26번의 시도를 해본다면 암호문을 복원할 수 있다.

Upper case letters are replaced with upper case letters, and lower case letters are replaced with lower case letters. Therefore, in the case of the alphabet, if ROT13 is twice (ROT13 + ROT13 = ROT26), it turns around once again and becomes the original letter.

대문자는 대문자끼리, 소문자는 소문자끼리 치환한다. 그러므로, 알파벳의 경우 ROT13을 두번(ROT13 + ROT13 = ROT26) 하면 한 바퀴를 돌아 다시 원래의 글자가 된다.

Caesar ciphers are unsuitable for modern cryptographic purposes, considering their difficulty, and are mainly used for quizzes and puzzles.

카이사르 암호는 그 난이도를 고려했을 때 현대의 암호화 목적으로는 부적합하며, 주로 퀴즈나 퍼즐 용도로 사용된다.

May 13, 2019

What is Base64



Base64

64 number system. The way data is expressed in 64 number system.

64진법. 데이터를 64진법으로 표현하는 방식.

The conversion of data to Base64 is said to encoding, and the opposite is said to decoding.

데이터를 Base64로 변환하는 것을 인코딩한다고 표현하고, 그 반대를 디코딩한다고 표현한다.

Since 2 ^ 6 = 64, 6 bits represent one character.

2^6 = 64이므로, 6bit로 문자 한 개를 표현한다.

In addition, the four 6 bits are converted together, which causes padding. In this case, the padding is filled with the "=" character.

또한 6bit를 4개씩 모아 변환하는데, 이 때문에 비는 공간(padding)이 발생한다. 이 경우, 빈 공간은 "=" 문자로 채운다.

In Base64 encoding, the size of the data increases by 33%.

Base64로 인코딩 시 데이터의 크기는 33% 증가한다.

The Base64 encoding example can be seen in the video.

Base64 인코딩 예시는 영상에서 확인할 수 있다.

May 10, 2019

What is Wildcard



와일드카드(Wildcard)

It is a word derived from a card game. It has the meaning of "substitutable card" and "universal card".

카드게임에서 유래된 단어로, "대용 가능한 카드", "만능패" 정도의 의미를 지닌다.

Wildcards on computers mean "special characters that can replace arbitrary characters".

컴퓨터에서의 와일드카드는 "임의의 문자를 대신할 수 있는 특수문자"를 의미한다.

Major wildcard
주요 와일드 카드

*: Any random string. 모든 임의 문자열

?: One random character. 하나의 임의 문자

[]: One specified character. 지정된 하나의 문자.

[^]: One character except the ones specified. 지정된 것들을 제외한 하나의 문자.

It is more useful to include the following string class in square brackets.
대괄호에 아래의 문자열 클래스가 포함되면 더욱 유용해진다.

[:alpha:] All uppercase/lowercase alphabets. 모든 대문자/소문자 알파벳.
[:upper:] All uppercase alphabets. 모든 대문자 알파벳.
[:lower:] All lowercase alphabets. 모든 소문자 알파벳.
[:alnum:] All uppercase/lowercase alphabets and all numbers. 모든 대문자/소문자 알파벳과 모든 숫자.
[:digit:] All numbers. 모든 숫자.

May 03, 2019

What is the Serialization



직렬화(Serialization)

The process of converting data of a specific structure, such as an object, into data of a form that can be restored later.

객체 등 특정 구조의 데이터를, 이후 복원할 수 있는 형태의 데이터로 전환하는 과정.

Deserialization is the opposite. The process of restoring serialized data.

역직렬화(Deserialization)는 그 반대. 직렬화된 데이터를 복원하는 과정.

Like the name serialization, usually serialized data is represented by a single line regardless of the length.

직렬화라는 이름에 걸맞게, 보통 직렬화된 데이터는 아무리 길어도 1줄로 표현된다.

마셜링(Marshaling) = 직렬화(Serialization)
디마셜링(Demarshaling) = 역직렬화(Deserialization)

Serialization, however, does not generate data in an existing way, so security flaws are identified.

그러나 직렬화는 기존의 방식으로 데이터를 생성하는 것이 아니기에, 이로 인한 보안상의 결함이 식별되기도 한다.

The reason for using serialization is to store or transfer the data outside the system.

직렬화를 하는 이유는 해당 데이터를 시스템 외부에 저장하거나 전송하기 위해서이다.

Deserialization, on the other hand, is used to load data that is stored or transmitted outside the system and then used after recovery.

역직렬화는 이와는 반대로, 시스템 외부에 저장되거나 전송된 데이터를 받아와 복구 후 사용하기 위해서다.

Flaws can occur with the trusted data within the system. If untrusted data is inflowed, the probability of occurrence of flaws increases.

신뢰할 수 있는 시스템 내부의 데이터만 가지고도 결함은 발생하기 마련인데, 신뢰할 수 없는 데이터가 유입된다면 결함 발생 확률은 당연히 증가하게 된다.

It is typical to transmit serialized data including a malicious code. Since this malicious code is restored at the time of deserialization (restoration), a system vulnerable to the malicious code, such as using an old library, may be exposed to an attack.

직렬화된 데이터에 악성코드를 심어 전달하는 것이 대표적인데, 역직렬화(복원) 시 이 악성코드도 함께 복원되기 때문에, 구버전의 라이브러리르 사용하는 등 해당 악성코드에 취약한 시스템의 경우 공격에 노출될 수 있다.