Original
The name of the girl on the statue of liberty is Mother of Exiles.
해석
자유의 여신상에 있는 소녀의 이름은 Mother of Exiles입니다.
단어
- statue : 조각상 (명사)
- liberty : 자유 (명사)
- girl : 소녀 (명사)
- Mother of Exiles : 유배자의 어머니 (명사구)
The name of the girl on the statue of liberty is Mother of Exiles.
자유의 여신상에 있는 소녀의 이름은 Mother of Exiles입니다.
- statue : 조각상 (명사)
- liberty : 자유 (명사)
- girl : 소녀 (명사)
- Mother of Exiles : 유배자의 어머니 (명사구)
The `Golden Arches` of fast food chain McDonalds is more recognized worldwide than the religious cross of Christianity.
패스트 푸드 체인 맥도날드의 '골든 아치'는 기독교의 십자가보다 전 세계적으로 더 잘 알려져 있다.
- Golden Arches: 맥도날드의 상징. (명사)
- fast food chain: 패스트 푸드 체인. (명사)
- McDonalds: 맥도날드. (명사)
- recognized: 인정받다. (동사)
- worldwide: 전 세계적으로. (부사)
- religious: 종교의. (형용사)
- cross: 십자가. (명사)
- Christianity: 기독교. (명사)
RSA의 공개키와 개인키를 XML 형식으로 생성하는 예제이다.
using System.Security.Cryptography;
public void CreateRSAKey()
{
using (RSA rsa = RSA.Create())
{
// 개인 키 추출
RSAParameters privateKeyParameters = rsa.ExportParameters(true);
// 개인 키를 TEXT 형식으로 출력
rsa.ImportParameters(privateKeyParameters);
string privateKeyText = rsa.ToXmlString(true);
Console.WriteLine("\n개인 키:\n" + privateKeyText);
// 공개 키 추출
RSAParameters publicKeyParameters = rsa.ExportParameters(false);
// 공개 키를 TEXT 형식으로 출력
rsa.ImportParameters(publicKeyParameters);
string publicKeyText = rsa.ToXmlString(false);
Console.WriteLine("공개 키:\n" + publicKeyText);
}
}
생성한 공개키를 이용해 암호화 하는 예제
public void Encrypt(string text)
{
RSACryptoServiceProvider rsa = new RSACryptoServiceProvider();
rsa.FromXmlString(publicKey);
byte[] utf = (new UTF8Encoding()).GetBytes(text);
byte[] encrypt = rsa.Encrypt(utf, false);
string result = Convert.ToBase64String(encrypt);
}
생성한 개인키를 이용해 복호화 하는 예제
public void Decrypt(string text)
{
RSACryptoServiceProvider rsa = new RSACryptoServiceProvider();
rsa.FromXmlString(privateKey);
byte[] base64 = Convert.FromBase64String(text);
byte[] decrypt = rsa.Decrypt(base64, false);
string dec = (new UTF8Encoding()).GetString(decrypt, 0, decrypt.Length);
string result = dec;
}
gRPC DateTime C# 예제 (0) | 2023.09.14 |
---|---|
C# Convert TimeSpan to DateTime (0) | 2023.09.14 |
Bcrypt는 단방향 암호화 알고리즘이기 때문에 복호화가 불가능하다.
따라서 암호화 된 hash 값과 hash 값 끼리는 검증이 불가능하다.
오로지 평문과 hash 값만 비교 가능하다.
1. .proto 파일에 "google/protobuf/timestamp.proto" 를 import 한다.
import "google/protobuf/timestamp.proto";
2. 파라미터 타입을 아래와같이 지정한다.
message TestRequest {
google.protobuf.Timestamp dt = 1;
}
3. C# 클라이언트에서는 아래와같이 파라미터를 가공한다.
var request = new TestRequest() {
dt = Timestamp.FromDateTime(DateTime.Now)
}
4. gRPC 서버에서는 파라미터를 아래와같이 가공한다.
DateTime dt2 = request.dt.ToDateTime();
C# RSA 키 생성 예제 (0) | 2023.09.14 |
---|---|
C# Convert TimeSpan to DateTime (0) | 2023.09.14 |
DateTime을 Time Span으로 바꾸는 방법은 아래와 같다.
DateTime dt = DateTime.Now;
TimeSpan span = TimeSpan.FromTicks(dt.Ticks);
Console.WriteLine(span);
반대로, TimeSpan 값을 DateTime 으로 바꾸는 방법은 아래 두가지 방법이 있다.
DateTime dt2 = new DateTime() + span;
DateTime dt3 = new DateTime(span.Ticks);
Console.WriteLine(dt2);
Console.WriteLine(dt3);
C# RSA 키 생성 예제 (0) | 2023.09.14 |
---|---|
gRPC DateTime C# 예제 (0) | 2023.09.14 |
Owls are one of the only birds who can see the color blue!
올빼미는 유일하게 파란색을 볼 수 있는 색을 볼 수 있는 새 중 하나입니다.
- Owls: 올빼미
- one: 하나의
- only: 유일한
- birds: 새들
- who: 누구
- can: 할 수 있다
- see: 보다
- color: 색
- blue: 파란색
If you went out into space, you would explode before you suffocated because there's no air pressure.
우주로 나가면 질식하기 전에 폭발할 것이다. 왜냐하면 공기압이 없기 때문이다.
- explode : 폭발하다 (동사)
- suffocate : 질식하다 (동사)
- air pressure : 대기압 (명사)
The longest one-syllable word in the English language is "screeched."
영어에서 가장 긴 한 음절 단어는 "screeched"입니다.
- screeched: 비명을 지르다 (동사)
ubuntu 20.04를 사용하면서 처음 겪는 현상이 있었다.
마우스가 커서를 움직이는 것은 가능하나 (좌/우)클릭만 안되는 것이었다.
이문제를 해결하기 위해 구글링을 해보다가 다음과 같은 명령어를 통해 해결할 수 있었다.
sudo udevadm trigger
[GO] hash/maphash: malformed module path "hash/maphash": missing dot in first… (0) | 2022.08.11 |
---|---|
[docker] E: Package 'locales' has no installation candidate (0) | 2022.08.08 |