__________     __ __     __  _______    ________
  / ____/ __ \   / // /    / / / /  _/ |  / / ____/
 / / __/ / / /  / // /_   / /_/ // / | | / / __/
/ /_/ / /_/ /  /__  __/  / __  // /  | |/ / /___
\____/\____/     /_/    /_/ /_/___/  |___/_____/

 --- A GOPHER-LIKE INTERFACE FOR HIVE BLOCKCHAIN ---

MSSQL Forensic을 위한 Query

BY: @forensicmon | CREATED: April 19, 2018, 2:13 p.m. | VOTES: 2 | PAYOUT: $0.00 | [ VOTE ]

데이터베이스는 그 양이 방대하여 삭제된 영역의 복구가 쉽지 않다. Apex라는 툴을 MS-SQL에서 제공하기는 하나, 이는 서버 관리 차원에서의 도구로 디지털 포렌식에 십분 활요하기 어렵다.

데이터베이스 내에서 삭제된 레코드를 복구하는 방법은 크게 다음 네 단계로 나눌 수 있다.

  1. Table List 획득
  2. Scheme 획득
  3. Table의 Data Page 리스트 획득
  4. Page의 미할당영역 탐색
  5. 복구

1~3 단계는 메타데이터를 획득하는 과정, 4~5는 실질적으로 복구하는 과정이다.

메타데이터를 획득하는 과정이 특히 중요한데, 조사관이 분석PC에서 압수한 DB를 SQL에 올릴 수 있는 경우에는 Query를 사용하여 DB 정보를 획득할 수 있다.

select name, id from sysobjects where type='U'
select COLUMN_NAME,DATA_TYPE,ORDINAL_POSITION from INFORMATION_SCHEMA.COLUMNS where TABLE_NAME = '[table name]'
select COLUMN_NAME,DATA_TYPE,ORDINAL_POSITION,CHARACTER_MAXIMUM_LENGTH from INFORMATION_SCHEMA.COLUMNS where TABLE_NAME = '[table name]'

dbcc traceon(3604)
go
dbcc ind (0,'[table name]',-1)

dbcc page(0,1,[page number],1)

일반적으로 DBCC (DataBase Consistency Checker)는 시스템 관리자의 DB관리를 목적으로 사용되나, 디지털 포렌식에서도 유용하게 사용된다. ( 참고 : http://msdn.microsoft.com/en-us/library/ms188796.aspx )

TAGS: [ #kr ] [ #database ] [ #mssql ] [ #forensics ] [ #query ]

Replies

@steemitboard | March 17, 2019, 5 a.m. | Votes: 0 | [ VOTE ]

Congratulations @forensicmon! You received a personal award!

https://steemitimages.com/70x70/http://steemitboard.com/@forensicmon/birthday1.pngHappy Birthday! - You are on the Steem blockchain for 1 year!

You can view your badges on your Steem Board and compare to others on the Steem Ranking

Do not miss the last post from @steemitboard:

Are you a DrugWars early adopter? Benvenuto in famiglia!

Vote for @Steemitboard as a witness to get one more award and increased upvotes!
@steemitboard | March 17, 2020, 2:39 a.m. | Votes: 0 | [ VOTE ]

Congratulations @forensicmon! You received a personal award!

https://steemitimages.com/70x70/http://steemitboard.com/@forensicmon/birthday2.pngHappy Steem Birthday! - You are on the Steem blockchain for 2 years!

You can view your badges on your Steem Board and compare to others on the Steem Ranking

Vote for @Steemitboard as a witness to get one more award and increased upvotes!
[ BACK TO TRENDING ] [ BACK TO MENU ]
CMD>