본문으로 건너뛰기

"튜토리얼" 태그로 연결된 2개 게시물개의 게시물이 있습니다.

단계별 가이드 및 튜토리얼

모든 태그 보기

@mysten/seal로 탈중앙화 암호화 구축하기: 개발자 튜토리얼

· 약 13분
Dora Noda
Software Engineer

프라이버시가 공공 인프라가 되고 있습니다. 2025년에 개발자들은 데이터 저장만큼 쉽게 암호화를 수행할 수 있는 도구가 필요합니다. Mysten Labs의 Seal은 바로 그것을 제공합니다—온체인 접근 제어가 있는 탈중앙화 비밀 관리입니다. 이 튜토리얼은 신원 기반 암호화, 임계값 보안, 프로그래밍 가능한 접근 정책을 사용하여 안전한 Web3 애플리케이션을 구축하는 방법을 알려드립니다.


소개: Web3에서 Seal이 중요한 이유

기존의 클라우드 애플리케이션은 단일 제공업체가 암호화된 데이터에 대한 접근을 제어하는 중앙화된 키 관리 시스템에 의존합니다. 편리하지만, 이는 위험한 단일 장애점을 만듭니다. 제공업체가 손상되거나, 오프라인이 되거나, 접근을 제한하기로 결정하면 데이터에 접근할 수 없거나 취약해집니다.

Seal은 이 패러다임을 완전히 바꿉니다. Sui 블록체인을 위해 Mysten Labs에서 구축한 Seal은 다음을 가능하게 하는 탈중앙화 비밀 관리(DSM) 서비스입니다:

  • 신원 기반 암호화 - 콘텐츠가 환경을 떠나기 전에 보호됩니다
  • 임계값 암호화 - 키 접근을 여러 독립적인 노드에 분산시킵니다
  • 온체인 접근 제어 - 시간 잠금, 토큰 게이팅, 커스텀 인증 로직
  • 스토리지 무관 설계 - Walrus, IPFS 또는 모든 스토리지 솔루션과 작동

안전한 메시징 앱, 게이티드 콘텐츠 플랫폼, 시간 잠금 자산 전송을 구축하든, Seal은 필요한 암호화 프리미티브와 접근 제어 인프라를 제공합니다.


시작하기

전제 조건

시작하기 전에 다음이 있는지 확인하세요:

  • Node.js 18+ 설치
  • TypeScript/JavaScript 기본 지식
  • 테스트용 Sui 지갑 (Sui Wallet 등)
  • 블록체인 개념에 대한 이해

설치

npm을 통해 Seal SDK를 설치합니다:

npm install @mysten/seal

블록체인 상호작용을 위해 Sui SDK도 필요합니다:

npm install @mysten/sui

프로젝트 설정

새 프로젝트를 생성하고 초기화합니다:

mkdir seal-tutorial
cd seal-tutorial
npm init -y
npm install @mysten/seal @mysten/sui typescript @types/node

간단한 TypeScript 구성을 생성합니다:

// tsconfig.json
{
"compilerOptions": {
"target": "ES2020",
"module": "commonjs",
"strict": true,
"esModuleInterop": true,
"skipLibCheck": true,
"forceConsistentCasingInFileNames": true
}
}

핵심 개념: Seal 작동 방식

코드를 작성하기 전에 Seal의 아키텍처를 이해해 봅시다:

1. 신원 기반 암호화 (IBE)

공개 키로 암호화하는 전통적인 암호화와 달리, IBE는 신원(이메일 주소나 Sui 주소 등)으로 암호화할 수 있게 해줍니다. 수신자는 해당 신원을 제어한다는 것을 증명할 수 있을 때만 복호화할 수 있습니다.

2. 임계값 암호화

단일 키 서버를 신뢰하는 대신, Seal은 t-of-n 임계값 체계를 사용합니다. 5개 중 3개 키 서버를 구성할 수 있으며, 이는 3개 서버가 협력하여 복호화 키를 제공할 수 있지만 2개 이하로는 불가능함을 의미합니다.

3. 온체인 접근 제어

접근 정책은 Sui 스마트 컨트랙트에 의해 시행됩니다. 키 서버가 복호화 키를 제공하기 전에 요청자가 온체인 정책 요구사항(토큰 소유권, 시간 제약 등)을 충족하는지 확인합니다.

4. 키 서버 네트워크

분산된 키 서버들이 접근 정책을 검증하고 복호화 키를 생성합니다. 이 서버들은 단일 제어점이 없도록 다른 당사자들에 의해 운영됩니다.


기본 구현: 첫 번째 Seal 애플리케이션

Sui 블록체인 정책을 통해 민감한 데이터를 암호화하고 접근을 제어하는 간단한 애플리케이션을 구축해 봅시다.

1단계: Seal 클라이언트 초기화

// src/seal-client.ts
import { SealClient } from '@mysten/seal';
import { SuiClient } from '@mysten/sui/client';

export async function createSealClient() {
// 테스트넷용 Sui 클라이언트 초기화
const suiClient = new SuiClient({
url: 'https://fullnode.testnet.sui.io'
});

// 테스트넷 키 서버로 Seal 클라이언트 구성
const sealClient = new SealClient({
suiClient,
keyServers: [
'https://keyserver1.seal-testnet.com',
'https://keyserver2.seal-testnet.com',
'https://keyserver3.seal-testnet.com'
],
threshold: 2, // 3개 중 2개 임계값
network: 'testnet'
});

return { sealClient, suiClient };
}

2단계: 간단한 암호화/복호화

// src/basic-encryption.ts
import { createSealClient } from './seal-client';

async function basicExample() {
const { sealClient } = await createSealClient();

// 암호화할 데이터
const sensitiveData = "이것은 내 비밀 메시지입니다!";
const recipientAddress = "0x742d35cc6d4c0c08c0f9bf3c9b2b6c64b3b4f5c6d7e8f9a0b1c2d3e4f5a6b7c8";

try {
// 특정 Sui 주소로 데이터 암호화
const encryptedData = await sealClient.encrypt({
data: Buffer.from(sensitiveData, 'utf-8'),
recipientId: recipientAddress,
// 선택적: 메타데이터 추가
metadata: {
contentType: 'text/plain',
timestamp: Date.now()
}
});

console.log('암호화된 데이터:', {
ciphertext: encryptedData.ciphertext.toString('base64'),
encryptionId: encryptedData.encryptionId
});

// 나중에 데이터 복호화 (적절한 인증 필요)
const decryptedData = await sealClient.decrypt({
ciphertext: encryptedData.ciphertext,
encryptionId: encryptedData.encryptionId,
recipientId: recipientAddress
});

console.log('복호화된 데이터:', decryptedData.toString('utf-8'));

} catch (error) {
console.error('암호화/복호화 실패:', error);
}
}

basicExample();

Sui 스마트 컨트랙트를 통한 접근 제어

Seal의 진정한 힘은 프로그래밍 가능한 접근 제어에서 나옵니다. 특정 시간 이후에만 데이터를 복호화할 수 있는 시간 잠금 암호화 예제를 만들어 봅시다.

1단계: 접근 제어 컨트랙트 배포

먼저 접근 정책을 정의하는 Move 스마트 컨트랙트가 필요합니다:

// contracts/time_lock.move
module time_lock::policy {
use sui::clock::{Self, Clock};
use sui::object::{Self, UID};
use sui::tx_context::{Self, TxContext};

public struct TimeLockPolicy has key, store {
id: UID,
unlock_time: u64,
authorized_user: address,
}

public fun create_time_lock(
unlock_time: u64,
authorized_user: address,
ctx: &mut TxContext
): TimeLockPolicy {
TimeLockPolicy {
id: object::new(ctx),
unlock_time,
authorized_user,
}
}

public fun can_decrypt(
policy: &TimeLockPolicy,
user: address,
clock: &Clock
): bool {
let current_time = clock::timestamp_ms(clock);
policy.authorized_user == user && current_time >= policy.unlock_time
}
}

2단계: Seal과 통합

// src/time-locked-encryption.ts
import { createSealClient } from './seal-client';
import { TransactionBlock } from '@mysten/sui/transactions';

async function createTimeLocked() {
const { sealClient, suiClient } = await createSealClient();

// Sui에서 접근 정책 생성
const txb = new TransactionBlock();

const unlockTime = Date.now() + 60000; // 1분 후 잠금 해제
const authorizedUser = "0x742d35cc6d4c0c08c0f9bf3c9b2b6c64b3b4f5c6d7e8f9a0b1c2d3e4f5a6b7c8";

txb.moveCall({
target: 'time_lock::policy::create_time_lock',
arguments: [
txb.pure(unlockTime),
txb.pure(authorizedUser)
]
});

// 정책 생성을 위한 트랜잭션 실행
const result = await suiClient.signAndExecuteTransactionBlock({
transactionBlock: txb,
signer: yourKeypair, // 당신의 Sui keypair
});

const policyId = result.objectChanges?.find(
change => change.type === 'created'
)?.objectId;

// 이제 이 정책으로 암호화
const sensitiveData = "이것은 1분 후에 잠금 해제됩니다!";

const encryptedData = await sealClient.encrypt({
data: Buffer.from(sensitiveData, 'utf-8'),
recipientId: authorizedUser,
accessPolicy: {
policyId,
policyType: 'time_lock'
}
});

console.log('시간 잠금 데이터가 생성되었습니다. 1분 후에 복호화를 시도해보세요.');

return {
encryptedData,
policyId,
unlockTime
};
}

실용적인 예제

예제 1: 보안 메시징 애플리케이션

// src/secure-messaging.ts
import { createSealClient } from './seal-client';

class SecureMessenger {
private sealClient: any;

constructor(sealClient: any) {
this.sealClient = sealClient;
}

async sendMessage(
message: string,
recipientAddress: string,
senderKeypair: any
) {
const messageData = {
content: message,
timestamp: Date.now(),
sender: senderKeypair.toSuiAddress(),
messageId: crypto.randomUUID()
};

const encryptedMessage = await this.sealClient.encrypt({
data: Buffer.from(JSON.stringify(messageData), 'utf-8'),
recipientId: recipientAddress,
metadata: {
type: 'secure_message',
sender: senderKeypair.toSuiAddress()
}
});

// 탈중앙화 스토리지(Walrus)에 암호화된 메시지 저장
return this.storeOnWalrus(encryptedMessage);
}

async readMessage(encryptionId: string, recipientKeypair: any) {
// 스토리지에서 검색
const encryptedData = await this.retrieveFromWalrus(encryptionId);

// Seal로 복호화
const decryptedData = await this.sealClient.decrypt({
ciphertext: encryptedData.ciphertext,
encryptionId: encryptedData.encryptionId,
recipientId: recipientKeypair.toSuiAddress()
});

return JSON.parse(decryptedData.toString('utf-8'));
}

private async storeOnWalrus(data: any) {
// Walrus 스토리지와의 통합
// 이는 암호화된 데이터를 Walrus에 업로드하고
// 검색을 위한 blob ID를 반환합니다
}

private async retrieveFromWalrus(blobId: string) {
// blob ID를 사용하여 Walrus에서 암호화된 데이터 검색
}
}

예제 2: 토큰 게이티드 콘텐츠 플랫폼

// src/gated-content.ts
import { createSealClient } from './seal-client';

class ContentGating {
private sealClient: any;
private suiClient: any;

constructor(sealClient: any, suiClient: any) {
this.sealClient = sealClient;
this.suiClient = suiClient;
}

async createGatedContent(
content: string,
requiredNftCollection: string,
creatorKeypair: any
) {
// NFT 소유권 정책 생성
const accessPolicy = await this.createNftPolicy(
requiredNftCollection,
creatorKeypair
);

// NFT 접근 요구사항으로 콘텐츠 암호화
const encryptedContent = await this.sealClient.encrypt({
data: Buffer.from(content, 'utf-8'),
recipientId: 'nft_holders', // NFT 보유자를 위한 특별한 수신자
accessPolicy: {
policyId: accessPolicy.policyId,
policyType: 'nft_ownership'
}
});

return {
contentId: encryptedContent.encryptionId,
accessPolicy: accessPolicy.policyId
};
}

async accessGatedContent(
contentId: string,
userAddress: string,
userKeypair: any
) {
// 먼저 NFT 소유권 확인
const hasAccess = await this.verifyNftOwnership(
userAddress,
contentId
);

if (!hasAccess) {
throw new Error('접근 거부: 필요한 NFT를 찾을 수 없습니다');
}

// 콘텐츠 복호화
const decryptedContent = await this.sealClient.decrypt({
encryptionId: contentId,
recipientId: userAddress
});

return decryptedContent.toString('utf-8');
}

private async createNftPolicy(collection: string, creator: any) {
// NFT 소유권을 확인하는 Move 컨트랙트 생성
// 정책 객체 ID 반환
}

private async verifyNftOwnership(user: string, contentId: string) {
// 사용자가 필요한 NFT를 소유하는지 확인
// NFT 소유권을 위해 Sui 쿼리
}
}

예제 3: 시간 잠금 자산 전송

// src/time-locked-transfer.ts
import { createSealClient } from './seal-client';

async function createTimeLockTransfer(
assetData: any,
recipientAddress: string,
unlockTimestamp: number,
senderKeypair: any
) {
const { sealClient, suiClient } = await createSealClient();

// Sui에서 시간 잠금 정책 생성
const timeLockPolicy = await createTimeLockPolicy(
unlockTimestamp,
recipientAddress,
senderKeypair,
suiClient
);

// 자산 전송 데이터 암호화
const transferData = {
asset: assetData,
recipient: recipientAddress,
unlockTime: unlockTimestamp,
transferId: crypto.randomUUID()
};

const encryptedTransfer = await sealClient.encrypt({
data: Buffer.from(JSON.stringify(transferData), 'utf-8'),
recipientId: recipientAddress,
accessPolicy: {
policyId: timeLockPolicy.policyId,
policyType: 'time_lock'
}
});

console.log(`자산이 ${new Date(unlockTimestamp)}까지 잠겼습니다`);

return {
transferId: encryptedTransfer.encryptionId,
unlockTime: unlockTimestamp,
policyId: timeLockPolicy.policyId
};
}

async function claimTimeLockTransfer(
transferId: string,
recipientKeypair: any
) {
const { sealClient } = await createSealClient();

try {
const decryptedData = await sealClient.decrypt({
encryptionId: transferId,
recipientId: recipientKeypair.toSuiAddress()
});

const transferData = JSON.parse(decryptedData.toString('utf-8'));

// 자산 전송 처리
console.log('자산 전송이 잠금 해제되었습니다:', transferData);

return transferData;
} catch (error) {
console.error('전송이 아직 잠금 해제되지 않았거나 접근이 거부되었습니다:', error);
throw error;
}
}

Walrus 탈중앙화 스토리지와의 통합

Seal은 Sui의 탈중앙화 스토리지 솔루션인 Walrus와 원활하게 작동합니다. 두 가지를 모두 통합하는 방법은 다음과 같습니다:

// src/walrus-integration.ts
import { createSealClient } from './seal-client';

class SealWalrusIntegration {
private sealClient: any;
private walrusClient: any;

constructor(sealClient: any, walrusClient: any) {
this.sealClient = sealClient;
this.walrusClient = walrusClient;
}

async storeEncryptedData(
data: Buffer,
recipientAddress: string,
accessPolicy?: any
) {
// Seal로 암호화
const encryptedData = await this.sealClient.encrypt({
data,
recipientId: recipientAddress,
accessPolicy
});

// Walrus에 암호화된 데이터 저장
const blobId = await this.walrusClient.store(
encryptedData.ciphertext
);

// Seal과 Walrus 정보를 모두 포함하는 참조 반환
return {
blobId,
encryptionId: encryptedData.encryptionId,
accessPolicy: encryptedData.accessPolicy
};
}

async retrieveAndDecrypt(
blobId: string,
encryptionId: string,
userKeypair: any
) {
// Walrus에서 검색
const encryptedData = await this.walrusClient.retrieve(blobId);

// Seal로 복호화
const decryptedData = await this.sealClient.decrypt({
ciphertext: encryptedData,
encryptionId,
recipientId: userKeypair.toSuiAddress()
});

return decryptedData;
}
}

// 사용 예제
async function walrusExample() {
const { sealClient } = await createSealClient();
const walrusClient = new WalrusClient('https://walrus-testnet.sui.io');

const integration = new SealWalrusIntegration(sealClient, walrusClient);

const fileData = Buffer.from('중요한 문서 내용');
const recipientAddress = '0x...';

// 암호화된 상태로 저장
const result = await integration.storeEncryptedData(
fileData,
recipientAddress
);

console.log('Blob ID로 저장됨:', result.blobId);

// 나중에 검색하고 복호화
const decrypted = await integration.retrieveAndDecrypt(
result.blobId,
result.encryptionId,
recipientKeypair
);

console.log('검색된 데이터:', decrypted.toString());
}

임계값 암호화 고급 구성

프로덕션 애플리케이션의 경우 여러 키 서버와 함께 사용자 정의 임계값 암호화를 구성하고 싶을 것입니다:

// src/advanced-threshold.ts
import { SealClient } from '@mysten/seal';

async function setupProductionSeal() {
// 여러 독립적인 키 서버로 구성
const keyServers = [
'https://keyserver-1.your-org.com',
'https://keyserver-2.partner-org.com',
'https://keyserver-3.third-party.com',
'https://keyserver-4.backup-provider.com',
'https://keyserver-5.fallback.com'
];

const sealClient = new SealClient({
keyServers,
threshold: 3, // 5개 중 3개 임계값
network: 'mainnet',
// 고급 옵션
retryAttempts: 3,
timeoutMs: 10000,
backupKeyServers: [
'https://backup-1.emergency.com',
'https://backup-2.emergency.com'
]
});

return sealClient;
}

async function robustEncryption() {
const sealClient = await setupProductionSeal();

const criticalData = "미션 크리티컬 암호화된 데이터";

// 높은 보안 보장으로 암호화
const encrypted = await sealClient.encrypt({
data: Buffer.from(criticalData, 'utf-8'),
recipientId: '0x...',
// 최대 보안을 위해 모든 5개 서버 필요
customThreshold: 5,
// 중복성 추가
redundancy: 2,
accessPolicy: {
// 다중 인증 요구사항
requirements: ['nft_ownership', 'time_lock', 'multisig_approval']
}
});

return encrypted;
}

보안 모범 사례

1. 키 관리

// src/security-practices.ts

// 좋은 방법: 안전한 키 유도 사용
import { generateKeypair } from '@mysten/sui/cryptography/ed25519';

const keypair = generateKeypair();

// 좋은 방법: 키를 안전하게 저장 (환경 변수 예제)
const keypair = Ed25519Keypair.fromSecretKey(
process.env.PRIVATE_KEY
);

// 나쁜 방법: 키를 하드코딩하지 마세요
const badKeypair = Ed25519Keypair.fromSecretKey(
"hardcoded-secret-key-12345" // 이렇게 하지 마세요!
);

2. 접근 정책 검증

// 암호화 전에 항상 접근 정책 검증
async function secureEncrypt(data: Buffer, recipient: string) {
const { sealClient } = await createSealClient();

// 수신자 주소 검증
if (!isValidSuiAddress(recipient)) {
throw new Error('유효하지 않은 수신자 주소');
}

// 정책이 존재하고 유효한지 확인
const policy = await validateAccessPolicy(policyId);
if (!policy.isValid) {
throw new Error('유효하지 않은 접근 정책');
}

return sealClient.encrypt({
data,
recipientId: recipient,
accessPolicy: policy
});
}

3. 오류 처리 및 대체 방안

// 견고한 오류 처리
async function resilientDecrypt(encryptionId: string, userKeypair: any) {
const { sealClient } = await createSealClient();

try {
return await sealClient.decrypt({
encryptionId,
recipientId: userKeypair.toSuiAddress()
});
} catch (error) {
if (error.code === 'ACCESS_DENIED') {
throw new Error('접근 거부: 권한을 확인하세요');
} else if (error.code === 'KEY_SERVER_UNAVAILABLE') {
// 백업 구성으로 재시도
return await retryWithBackupServers(encryptionId, userKeypair);
} else if (error.code === 'THRESHOLD_NOT_MET') {
throw new Error('사용 가능한 키 서버가 부족합니다');
} else {
throw new Error(`복호화 실패: ${error.message}`);
}
}
}

4. 데이터 검증

// 암호화 전에 데이터 검증
function validateDataForEncryption(data: Buffer): boolean {
// 크기 제한 확인
if (data.length > 1024 * 1024) { // 1MB 제한
throw new Error('암호화하기에 데이터가 너무 큽니다');
}

// 민감한 패턴 확인 (선택사항)
const dataStr = data.toString();
if (containsSensitivePatterns(dataStr)) {
console.warn('경고: 데이터에 잠재적으로 민감한 패턴이 포함되어 있습니다');
}

return true;
}

성능 최적화

1. 작업 일괄 처리

// 효율성을 위해 여러 암호화를 일괄 처리
async function batchEncrypt(dataItems: Buffer[], recipients: string[]) {
const { sealClient } = await createSealClient();

const promises = dataItems.map((data, index) =>
sealClient.encrypt({
data,
recipientId: recipients[index]
})
);

return Promise.all(promises);
}

2. 키 서버 응답 캐싱

// 지연 시간을 줄이기 위해 키 서버 세션 캐시
class OptimizedSealClient {
private sessionCache = new Map();

async encryptWithCaching(data: Buffer, recipient: string) {
let session = this.sessionCache.get(recipient);

if (!session || this.isSessionExpired(session)) {
session = await this.createNewSession(recipient);
this.sessionCache.set(recipient, session);
}

return this.encryptWithSession(data, session);
}
}

Seal 통합 테스트

단위 테스트

// tests/seal-integration.test.ts
import { describe, it, expect } from 'jest';
import { createSealClient } from '../src/seal-client';

describe('Seal 통합', () => {
it('데이터를 성공적으로 암호화하고 복호화해야 합니다', async () => {
const { sealClient } = await createSealClient();
const testData = Buffer.from('테스트 메시지');
const recipient = '0x742d35cc6d4c0c08c0f9bf3c9b2b6c64b3b4f5c6d7e8f9a0b1c2d3e4f5a6b7c8';

const encrypted = await sealClient.encrypt({
data: testData,
recipientId: recipient
});

expect(encrypted.encryptionId).toBeDefined();
expect(encrypted.ciphertext).toBeDefined();

const decrypted = await sealClient.decrypt({
ciphertext: encrypted.ciphertext,
encryptionId: encrypted.encryptionId,
recipientId: recipient
});

expect(decrypted.toString()).toBe('테스트 메시지');
});

it('접근 제어 정책을 시행해야 합니다', async () => {
// 인증되지 않은 사용자는 복호화할 수 없음을 테스트
const { sealClient } = await createSealClient();

const encrypted = await sealClient.encrypt({
data: Buffer.from('비밀'),
recipientId: 'authorized-user'
});

await expect(
sealClient.decrypt({
ciphertext: encrypted.ciphertext,
encryptionId: encrypted.encryptionId,
recipientId: 'unauthorized-user'
})
).rejects.toThrow('접근 거부');
});
});

프로덕션 배포

환경 구성

// config/production.ts
export const productionConfig = {
keyServers: [
process.env.KEY_SERVER_1,
process.env.KEY_SERVER_2,
process.env.KEY_SERVER_3,
process.env.KEY_SERVER_4,
process.env.KEY_SERVER_5
],
threshold: 3,
network: 'mainnet',
suiRpc: process.env.SUI_RPC_URL,
walrusGateway: process.env.WALRUS_GATEWAY,
// 보안 설정
maxDataSize: 1024 * 1024, // 1MB
sessionTimeout: 3600000, // 1시간
retryAttempts: 3
};

모니터링 및 로깅

// utils/monitoring.ts
export class SealMonitoring {
static logEncryption(encryptionId: string, recipient: string) {
console.log(`[SEAL] ${recipient}에 대해 데이터 ${encryptionId} 암호화됨`);
// 모니터링 서비스로 전송
}

static logDecryption(encryptionId: string, success: boolean) {
console.log(`[SEAL] 복호화 ${encryptionId}: ${success ? '성공' : '실패'}`);
}

static logKeyServerHealth(serverUrl: string, status: string) {
console.log(`[SEAL] 키 서버 ${serverUrl}: ${status}`);
}
}

리소스 및 다음 단계

공식 문서

커뮤니티 및 지원

  • Sui Discord: 커뮤니티 지원을 위한 #seal 채널 참여
  • GitHub Issues: 버그 신고 및 기능 요청
  • 개발자 포럼: 토론을 위한 Sui 커뮤니티 포럼

탐구할 고급 주제

  1. 커스텀 접근 정책: Move 컨트랙트로 복잡한 인증 로직 구축
  2. 크로스 체인 통합: 다른 블록체인 네트워크와 함께 Seal 사용
  3. 엔터프라이즈 키 관리: 자체 키 서버 인프라 설정
  4. 감사 및 컴플라이언스: 규제 환경을 위한 로깅 및 모니터링 구현

샘플 애플리케이션

  • 보안 채팅 앱: Seal을 사용한 엔드 투 엔드 암호화 메시징
  • 문서 관리: 접근 제어가 있는 엔터프라이즈 문서 공유
  • 디지털 권한 관리: 사용 정책이 있는 콘텐츠 배포
  • 프라이버시 보존 분석: 암호화된 데이터 처리 워크플로우

결론

Seal은 Web3에서 프라이버시와 암호화를 인프라 수준의 관심사로 만드는 근본적인 변화를 나타냅니다. 신원 기반 암호화, 임계값 보안, 프로그래밍 가능한 접근 제어를 결합하여 개발자들에게 진정으로 안전하고 탈중앙화된 애플리케이션을 구축할 수 있는 강력한 도구를 제공합니다.

Seal로 구축하는 주요 장점은 다음과 같습니다:

  • 단일 장애점 없음: 분산된 키 서버가 중앙 권한을 제거
  • 프로그래밍 가능한 보안: 스마트 컨트랙트 기반 접근 정책이 유연한 인증 제공
  • 개발자 친화적: TypeScript SDK가 기존 Web3 도구와 원활하게 통합
  • 스토리지 무관: Walrus, IPFS 또는 모든 스토리지 솔루션과 작동
  • 프로덕션 준비: 엔터프라이즈 보안 표준으로 Mysten Labs에서 구축

사용자 데이터 보안, 구독 모델 구현, 복잡한 다자간 애플리케이션 구축 등 무엇을 하든, Seal은 자신감을 가지고 구축하는 데 필요한 암호화 프리미티브와 접근 제어 인프라를 제공합니다.

오늘부터 구축을 시작하고, 프라이버시를 공공 인프라의 기본 부분으로 만드는 개발자들의 성장하는 생태계에 참여하세요.


구축을 시작할 준비가 되셨나요? @mysten/seal을 설치하고 이 튜토리얼의 예제로 실험을 시작하세요. 탈중앙화 웹은 프라이버시와 보안을 우선시하는 애플리케이션을 기다리고 있습니다.

Sui Move와 함께 블록체인 프로그래밍 탐험하기

· 약 3분
Dora Noda
Software Engineer

블록체인 기술은 디지털 세계에서 선도적인 힘으로 부상했으며, 암호화폐를 넘어서는 혁신적인 솔루션을 제공하고 있습니다. 블록체인 전용 프로그래밍 언어들은 자신만의 독특한 영역을 개척하고 있습니다. 그 중에서도 Move는 견고함과 고유한 보안 기능 덕분에 중요한 위치를 차지하고 있습니다. 오늘은 예제 중심 학습 방식을 통해 개발자에게 Move 프로그래밍 언어를 가르치는 혁신적인 튜토리얼 “Sui Move”를 소개합니다.

Sui Move와 함께 블록체인 프로그래밍에 뛰어들다

Move 이해하기: 프로그래밍 언어

튜토리얼에 들어가기 전에 Move가 무엇인지 간략히 살펴보겠습니다. 페이스북 자회사인 Diem Association(전 Libra)에서 만든 Move는 정적 타입이며 리소스 지향적인 프로그래밍 언어입니다. 안전성과 보안을 강제하도록 설계되어 블록체인 및 암호화폐 프로젝트 코딩에 최적화된 언어입니다. Sui Move는 Move 프로그래밍 언어의 변형입니다.

Move에서 리소스는 다른 블록체인 프로그래밍 언어와 차별화되는 핵심 개념입니다. 리소스는 복사하거나 폐기할 수 없고, 오직 저장 위치 간에 이동만 가능합니다. 이 특성은 디지털 자산을 정밀하게 제어할 수 있게 해 주며, 이중 지불과 같은 일반적인 보안 위험을 크게 완화합니다.

Sui Move: 예제 중심 학습 튜토리얼

https://blockeden.xyz/docs/sui/sui-move/intro/에 위치한 “Sui Move”는 Move 프로그래밍 언어를 사용해 코딩하는 방법을 가르치는 종합적인 예제 중심 튜토리얼입니다.

“Sui Move”는 실습을 통한 학습이 이해와 숙련도를 가속화한다는 철학에 기반합니다. 튜토리얼은 각각 특정 Move 개념에 초점을 맞춘 작고 관리하기 쉬운 단위로 나뉘어 있습니다. 이를 통해 학습자는 언어의 기술적 세부 사항을 이해할 뿐만 아니라 실제 적용 방법까지 파악할 수 있습니다.

“Sui Move”는 교육 방식에서도 차별화됩니다. 무거운 이론에 압도되지 않도록 각 개념마다 풍부한 예제를 제공하며, 학습자는 이 예제들을 직접 실행해 보면서 깊이 있는 탐구와 이해를 경험합니다.

이 튜토리얼은 다양한 경험 수준에 맞게 설계되었습니다. 블록체인 개발에 뛰어들고자 하는 숙련된 개발자이든, 이제 막 시작하는 초보자이든, “Sui Move”는 개념을 효과적으로 습득하고 마스터할 수 있도록 맞춤형 학습 경로를 제공합니다.

학습 목표

“Sui Move”는 Move 프로그래밍 언어의 핵심을 이루는 다양한 주제를 다룹니다. 기대할 수 있는 내용은 다음과 같습니다:

  • Move의 문법 및 구조 이해
  • Move 고유의 리소스 지향 모델 심층 탐구
  • Move 함수와 메서드를 활용한 데이터 조작
  • 모듈(Module)과 스크립트(Script) 작성 및 구현
  • 예외 처리와 보안 강화 방법
  • 커스텀 코인 및 NFT 생성 방법 학습

왜 Sui Move를 선택해야 할까요?

“Sui Move”는 단순한 튜토리얼이 아니라 체계적인 학습 여정입니다. 제공되는 장점은 다음과 같습니다:

  1. 실제 사례 중심: 모든 개념마다 실무에서 바로 활용 가능한 예제가 함께 제공됩니다.
  2. 포괄적 커버리지: 기본 문법부터 고급 구조까지 Move를 전반적으로 이해할 수 있습니다.
  3. 단계별 가이드: 각 모듈이 점진적으로 난이도를 높여 학습 곡선을 완화하고 복잡한 개념을 쉽게 습득하도록 돕습니다.
  4. 유연성: 초보자부터 경험 많은 개발자까지 다양한 학습자에게 맞춤형 학습 경험을 제공합니다.

블록체인 기술은 수많은 산업의 미래를 형성하고 있으며, Move와 같은 언어를 마스터하면 개발자는 새로운 가능성을 열 수 있습니다. “Sui Move”와 함께라면 학습 여정을 효과적으로 안내받을 수 있습니다. 지금 바로 뛰어들어 코딩을 시작하고, Move와 블록체인 기술이 제공하는 흥미로운 기회를 탐험해 보세요.

지금 시작하기: https://blockeden.xyz/docs/sui/sui-move/intro/.