Skip to main content

15) SOM 파일 생성

SOM 파일 생성

API

MethodURL
POST/api/som/internal/createFile

Request Header

NameRequiredDescription
Authorizationrequired사용자 인증 수단, JWT값
Authorization: Bearer {JWT}
참고 : JWT값은 인증/인가 서비스를 통해 발급 받는다.

Request Body

NameRequiredTypeDescription
companyIdrequiredstringSHIELDRM 관리자 페이지의 연동 앱 관리 메뉴에서 발급 받은 라이선스 입력
srcFilePathrequiredstring원본파일 절대 경로
- 해당 문서가 이미 som 파일인 경우 파일 복사 후 성공 리턴
dstFilePathrequiredstring생성될 외부전송 보안파일 절대경로
- 파일 확장자명은 exe로 표기하여야 함
somSetRightsrequiredarrayStringSLSomFileLinker.DSSOMSetRights() 함수로 설정한 권한
propertiesrequiredjsonStringdssom.properties로 설정한 옵션
somSetRights
indexTypeDescription
0string패스워드 문자열
- 패스워드는 영문과 숫자로만 가능
1int다른 이름 저장 권한
2int프린트 권한
3int읽기 횟수
4int프린트 횟수
5int파기 권한
6int유효기간
7intOLESOM Viewer 지원
8intImage Viewer 지원
9intText Viewer 지원
10intUse UI Version(1, 2(Defaule;DS4.0))
11booleanUse Unicode(true(Default), False)
12stringMAC address 가 같은 pc에서만 오픈 가능
properties (dssom.properties 참고)
NameTypeDescription
DSKEYENCRYPT_KEYstringSOM 생성을 위한 고정키 입력(EKDATA2)
...

Response

NameTypeDescription
codeint0 : 성공
이외의 값 : 에러
messagestring실패 시 에러 메시지

Examples

Request

  • Body
{
"companyId": "7FDKQsEK-QVGKyXA2-fx1LxIzy-SNIre0s9",
"srcFilePath": "D:\\opt\\shieldrm\\data\\test\\test.pptx",
"dstFilePath": "D:\\opt\\shieldrm\\data\\test\\test.exe",
"somSetRights": "[\"1111\",1,1,2,0,1,1,1,0,0,2,true,\"10-FF-E0-7F-06-C6\"]",
"properties": "{\"SiteInfo\":\"\",\"DocUIDWithoutMAC\":0,\"DSKEYENCRYPT_KEY\":\"EhH9NMxViK0XFXho/DEZZg==\",\"useDSvFive\":0,\"useAutoGenDocUID\":1,\"useHashDispersed\":1,\"LimitPwdFail\":0}"
}

Response

  • 성공
{
"code": 0,
"message": "OK"
}
  • 실패
  • Status code : 500 INTERNAL_SERVER_ERROR
[SDF 컨테이너 모듈(SCSL) 에러]
{
"code": -61,
"message": "EXCEPTION error"
}