KR20090035382A - Secure user session managing method and system under web environment, recording medium recorded program executing it - Google Patents

Secure user session managing method and system under web environment, recording medium recorded program executing it Download PDF

Info

Publication number
KR20090035382A
KR20090035382A KR1020070100638A KR20070100638A KR20090035382A KR 20090035382 A KR20090035382 A KR 20090035382A KR 1020070100638 A KR1020070100638 A KR 1020070100638A KR 20070100638 A KR20070100638 A KR 20070100638A KR 20090035382 A KR20090035382 A KR 20090035382A
Authority
KR
South Korea
Prior art keywords
client
server
session
authentication value
shared key
Prior art date
Application number
KR1020070100638A
Other languages
Korean (ko)
Other versions
KR100915003B1 (en
Inventor
양대헌
맹영재
Original Assignee
인하대학교 산학협력단
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 인하대학교 산학협력단 filed Critical 인하대학교 산학협력단
Priority to KR1020070100638A priority Critical patent/KR100915003B1/en
Priority to US11/965,941 priority patent/US20090094372A1/en
Publication of KR20090035382A publication Critical patent/KR20090035382A/en
Application granted granted Critical
Publication of KR100915003B1 publication Critical patent/KR100915003B1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W12/00Security arrangements; Authentication; Protecting privacy or anonymity
    • H04W12/08Access security
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/30Public key, i.e. encryption algorithm being computationally infeasible to invert or user's encryption keys not requiring secrecy
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/32Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W80/00Wireless network protocols or protocol adaptations to wireless operation
    • H04W80/08Upper layer protocols
    • H04W80/10Upper layer protocols adapted for application session management, e.g. SIP [Session Initiation Protocol]

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computing Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Information Transfer Between Computers (AREA)
  • Computer And Data Communications (AREA)

Abstract

A method for safely managing a session of a user and a recording medium recording a program by using an authentication algorithm are provided to protect a user session by applying the authentication algorithm to an HTTP(HyperText Transfer Protocol) and use the other storage space for storing a secret key on a web browser. A random number generator(21) produces a client and a shared random number. An authenticator output unit(22) produces s server authenticator. The server authenticator is a result value stored with the generated random number. An authenticator comparison unit(23) is transmitted from a server authenticator and a client. An authentication management unit(24) determines whether to success of transmitter authentication of the client according to a comparison result. In case authentication succeeds in, it is determined as the HTTP request from the suitable client and session is maintained.

Description

웹 환경에서의 안전한 사용자 세션 관리 방법 및 시스템, 이를 수행하는 프로그램이 기록된 기록매체{Secure user session managing method and system under web environment, recording medium recorded program executing it}Secure user session managing method and system under web environment, recording medium recorded program executing it}

본 발명은 웹 환경에서의 안전한 사용자 세션 관리 방법 및 시스템에 관한 것이다. The present invention relates to a method and system for secure user session management in a web environment.

일반적으로 웹 환경은 개방형 환경으로 불특정 다수의 사용자가 접속하여 웹 서비스를 받는다. 웹 서비스에서 세션이란 상태 정보를 유지하지 않는 HTTP(hypertext transfer protocol: 인터넷에서, 웹 서버와 사용자의 인터넷 브라우저 사이에 문서를 전송하기 위해 사용되는 통신 규약) 프로토콜에서 한 사용자가 연속적으로 요청하는 일련의 서비스 요구를 처리하기 위하여 서버(server)와 클라이언트(client)에서 저장하고 주고 받는 정보를 의미한다. In general, the web environment is an open environment in which a large number of unspecified users access and receive web services. In web services, a session is a series of consecutive requests from a user in the hypertext transfer protocol (HTTP) protocol, which is used to transfer documents between a web server and a user's Internet browser. Refers to information stored and exchanged between a server and a client in order to process a service request.

웹 환경에서 사용자의 세션을 관리하기 위하여 기존에는 클라이언트가 가진 쿠키(cookie)를 이용하여 사용자를 구분하거나 인증하였다. 일례로, 쿠키에 사용자 의 IP, 해쉬된 사용자의 패스워드, 전자 서명을 유지하는 방법이 있다. In order to manage a user's session in a web environment, the user has been previously identified or authenticated using a cookie of the client. For example, a cookie may contain a user's IP, a hashed user's password, and a digital signature.

하지만, 클라이언트가 가진 쿠키는 HTTP 요청(HTTP request) 때마다 서버에 평문 형태로 자동 전송되기 때문에 쿠키에 포함된 정보가 공격자(attacker)에게 노출되는 문제점이 있다. 그리고 IP 스푸핑(spoofing)이나 오프라인 사전단어 공격(offline dictionary attack)에 취약하여 쿠키를 이용하여 사용자의 세션을 보호하는데 근본적인 해결책이 될 수 없는 문제점이 있다. However, since the cookie of the client is automatically sent to the server in plain text every HTTP request, the information contained in the cookie is exposed to an attacker. In addition, there is a problem that cannot be a fundamental solution in protecting a user's session by using a cookie because it is vulnerable to IP spoofing or offline dictionary attack.

즉, 사용자의 세션 유지에 사용되는 쿠키는 도청(sniffing) 등을 통해 쉽게 노출될 수 있다. 이를 방지하기 위한 액티브X(ActiveX)는 사용자에게 부담이 되거나 편리성을 제공하지 못하는 문제점이 있다. 또한, 액티브X 자체의 설치에 문제가 발생하는 경우에는 웹 서비스에 접근조차 불가능한 경우도 발생한다. That is, the cookie used to maintain the session of the user can be easily exposed through sniffing or the like. ActiveX to prevent this has a problem that does not burden the user or provide convenience. Also, if you have a problem installing ActiveX itself, you may not even be able to access Web services.

본 발명은 시도-응답(challenge-response) 방식의 인증 알고리즘을 HTTP 프로토콜에 적용하여 사용자의 세션 보호가 가능한 사용자 세션 관리 방법 및 시스템, 이를 수행하는 프로그램이 기록된 기록매체를 제공한다. The present invention provides a user session management method and system capable of protecting a user's session by applying a challenge-response authentication algorithm to the HTTP protocol, and a recording medium having recorded thereon a program for performing the same.

또한, 본 발명은 웹 브라우저에서 비밀키를 저장하기 위하여 쿠키가 아닌 다른 저장 공간을 이용함으로써 평문 형태로 자동 전송되는 종래 쿠키의 단점을 극복한 사용자 세션 관리 방법 및 시스템, 이를 수행하는 프로그램이 기록된 기록매체를 제공한다. In addition, the present invention is a method and system for managing a user session that overcomes the shortcomings of conventional cookies that are automatically transmitted in plain text by using a storage space other than a cookie for storing a secret key in a web browser, and a program for performing the same. Provide a record carrier.

본 발명의 일 측면에 따르면, 웹 환경에서 네트워크를 통해 클라이언트와 연결된 서버에서 상기 클라이언트와의 사용자 세션을 관리하는 방법이 제공된다. According to an aspect of the present invention, a method for managing a user session with a client in a server connected to the client via a network in a web environment is provided.

사용자 세션 관리 방법은, 상기 서버가 상기 클라이언트로부터 쿠키(cookie)를 포함하는 제1 HTTP 요청(HTTP request)을 전송받는 단계-여기서, 상기 쿠키는 클라이언트 인증값을 포함하고, 상기 클라이언트 인증값은 상기 클라이언트에 저장된 공유키와 상기 클라이언트가 직전에 전송받은 제1 HTTP 응답(HTTP response)에 포함된 세션정보를 이용하여 계산됨-; 상기 쿠키에 포함된 클라이언트 인증값과 서버 인증값을 비교하는 단계-상기 서버 인증값은 상기 서버가 생성하여 상기 제1 HTTP 응답에 포함된 세션정보와 상기 서버에 저장된 공유키를 이용하여 계산됨-; 및 상기 비교 결과에 따라 상기 클라이언트의 송신자 인증 성공 또는 실패를 결정하는 단계를 포함한다. The user session management method, the server receiving a first HTTP request (HTTP request) including a cookie from the client, wherein the cookie includes a client authentication value, the client authentication value is the Calculated using a shared key stored in a client and session information included in a first HTTP response received immediately before the client; Comparing the client authentication value and the server authentication value included in the cookie, wherein the server authentication value is calculated using the session information generated by the server and included in the first HTTP response and the shared key stored in the server; ; And determining success or failure of sender authentication of the client according to the comparison result.

상기 서버는 상기 클라이언트로부터의 사용자 로그인 과정에서 상기 공유키를 상기 클라이언트와 공유할 수 있다. The server may share the shared key with the client during a user login process from the client.

한편, 상기 제1 HTTP 요청은 송신자 인증을 필요로 할 수 있다.Meanwhile, the first HTTP request may require sender authentication.

또한, 상기 송신자 인증 성공 또는 실패 결정 단계는, 상기 서버 인증값과 상기 클라이언트 인증값이 동일한 경우 상기 사용자 세션이 유효한 것으로 간주하여 상기 세션정보를 갱신하고, 상기 갱신한 세션정보에 상응하는 서버 인증값을 계산하며, 상기 제1 HTTP 요청에 대한 제2 HTTP 응답에 상기 갱신한 세션정보를 포함시켜 상기 클라이언트에 전송할 수 있다. 여기서, 상기 사용자 세션이 유효한 것으 로 간주하는 경우 상기 제2 HTTP 응답은 상기 클라이언트가 저장하고 있는 공유키와 상기 제2 HTTP 응답에 포함된 상기 세션정보를 이용하여 일방향 함수로 상기 클라이언트 인증값을 계산하고, 상기 클라이언트 인증값을 상기 쿠키에 포함시키도록 하는 실행코드를 포함할 수 있다. 그리고 상기 서버 인증값은 상기 클라이언트 인증값을 계산한 일방향 함수와 동일한 함수로 계산할 수 있다. In the determining of whether the sender authentication succeeds or fails, if the server authentication value and the client authentication value are the same, the sender authentication is regarded as valid and the session information is updated, and the server authentication value corresponding to the updated session information is updated. May be calculated and include the updated session information in a second HTTP response to the first HTTP request and transmit it to the client. Here, when the user session is regarded as valid, the second HTTP response calculates the client authentication value using a one-way function by using the shared key stored by the client and the session information included in the second HTTP response. And executable code for including the client authentication value in the cookie. The server authentication value may be calculated using the same function as the one-way function for calculating the client authentication value.

한편, 상기 인증 성공 또는 실패 결정 단계는, 상기 서버 인증값과 상기 클라이언트 인증값이 다른 경우 상기 사용자 세션이 유효하지 않은 것으로 간주하여 상기 서버는 상기 사용자 세션을 삭제할 수 있다. 상기 사용자 세션이 유효하지 않은 것으로 간주하는 경우 상기 서버는 상기 클라이언트의 상기 공유키, 상기 세션정보, 상기 클라이언트 인증값 및 상기 쿠키 중 적어도 하나를 NULL로 만드는 클라이언트측 스크립트(Client Side Script), 플래시(Flash) 또는 액티브X(ActiveX)를 상기 클라이언트에 전송할 수 있다. Meanwhile, in the authentication success or failure determination step, when the server authentication value and the client authentication value are different, the server may consider the user session invalid and delete the user session. If the user session is considered invalid, the server may generate at least one of the client's shared key, the session information, the client authentication value, and the cookie to NULL. Flash) or ActiveX can be sent to the client.

또한, 상기 서버는 상기 클라이언트와 상기 공유키를 공유하는 단계; 상기 클라이언트로부터 제2 HTTP 요청을 전송받는 단계; 상기 세션정보를 생성하는 단계; 및 상기 세션정보를 상기 제2 HTTP 요청에 대한 상기 제1 HTTP 응답에 포함시켜 상기 클라이언트에 전송하는 단계가 선행할 수 있다. The server may also share the shared key with the client; Receiving a second HTTP request from the client; Generating the session information; And including the session information in the first HTTP response to the second HTTP request and transmitting the session information to the client.

또한, 상기 서버는 웹 어플리케이션에서 제공하는 세션 또는 데이터베이스에 상기 공유키, 상기 세션정보와 상기 서버 인증값을 저장할 수 있다. The server may store the shared key, the session information, and the server authentication value in a session or database provided by a web application.

그리고 상기 서버는 상기 제1 HTTP 응답시 HTTP 내용 중 일부를 상기 공유키를 이용하여 암호화하고, 이를 복호화할 수 있는 클라이언트측 스크립트, 플래시 또는 액티브X를 포함하여 상기 클라이언트에 전송하는 단계를 더 포함함 수 있다.The server may further include encrypting a part of the HTTP content by using the shared key in the first HTTP response, and transmitting the same to the client, including a client-side script, flash, or ActiveX, which can decrypt the content. Can be.

한편, 상기 서버는 상기 제1 HTTP 응답시 상기 클라이언트가 HTTP 내용 중 일부를 암호화할 수 있도록 하는 암호 루틴을 포함하여 상기 클라이언트에 전송하는 단계를 더 포함하되, 상기 클라이언트는 상기 암호 루틴에 따라 상기 공유키를 이용하여 상기 HTTP 내용 중 일부가 암호화된 상기 제1 HTTP 요청을 상기 서버에 전송할 수 있다. On the other hand, the server further comprises the step of transmitting to the client including a cryptographic routine that allows the client to encrypt some of the HTTP content in the first HTTP response, wherein the client is the shared according to the cryptographic routine The first HTTP request in which a portion of the HTTP content is encrypted may be transmitted to the server using a key.

상기 세션정보는 난수(random number)일 수 있다.The session information may be a random number.

또는 상기 세션정보는 난수와 키 변형 인수를 포함할 수 있다. 상기 서버 인증값은 상기 서버에 저장된 상기 공유키 및 상기 키 변형 인수를 이용하여 계산한 서버 비밀키와, 상기 난수를 인수로 하는 일방향 함수로 계산될 수 있다. 상기 클라이언트 인증값은 상기 클라이언트에 저장된 상기 공유키 및 상기 클라이언트가 상기 서버로부터 전송받은 상기 제1 HTTP 응답에 포함된 상기 키 변형 인수를 이용하여 계산한 클라이언트 비밀키와, 상기 제1 HTTP 응답에 포함된 상기 난수를 인수로 하는 일방향 함수로 계산될 수 있다. Alternatively, the session information may include a random number and a key modification factor. The server authentication value may be calculated as a server secret key calculated using the shared key and the key modification factor stored in the server, and a one-way function having the random number as an argument. The client authentication value is included in the first HTTP response and the client secret key calculated using the shared key stored in the client and the key modification factor included in the first HTTP response received by the client from the server. It can be calculated as a one-way function taking the random number.

한편, 상술한 사용자 세션 관리 방법은 컴퓨터에 의하여 수행될 수 있으며, 컴퓨터에서 실행하기 위한 프로그램을 기록하는 컴퓨터 판독 가능한 기록매체에 기록되어 서버에서 수행될 수 있다. Meanwhile, the above-described user session management method may be performed by a computer, and may be recorded on a computer-readable recording medium for recording a program to be executed on the computer, and then performed by a server.

본 발명의 다른 측면에 따르면, 웹 환경에서 네트워크를 통해 서버와 연결된 클라이언트에서 사용자 세션을 관리하는 방법이 제공된다. According to another aspect of the present invention, a method for managing a user session in a client connected to a server via a network in a web environment is provided.

사용자 세션 관리 방법은, 상기 클라이언트가 상기 서버와 공유키를 공유하 는 단계; 상기 공유키를 웹 브라우저의 문서 객체 모델(DOM: Document Object Model)의 윈도우 객체의 속성 중 윈도우 이름(window.name), 플래시(Flash)의 지역 공유 객체(LSO: Local Shared Object) 또는 액티브X에 저장하는 단계; 상기 서버로부터의 HTTP 응답을 전송받는 단계-상기 HTTP 응답은 상기 서버에서 생성된 세션정보를 포함함-; 상기 세션정보와 상기 공유키를 이용하여 클라이언트 인증값을 계산하는 단계; 및 상기 클라이언트 인증값을 쿠키에 저장하는 단계를 포함한다. A user session management method includes the steps of: sharing a shared key with the server by the client; The shared key may be assigned to a window name (window.name), a local shared object (LSO) or ActiveX of a window object of a document object model (DOM) of a web browser. Storing; Receiving an HTTP response from the server, wherein the HTTP response includes session information generated at the server; Calculating a client authentication value using the session information and the shared key; And storing the client authentication value in a cookie.

송신자 인증이 필요한 HTTP 요청시 상기 쿠키를 포함하여 상기 서버에 전송하는 단계를 더 포함할 수 있다.The method may further include transmitting the cookie to the server in response to an HTTP request requiring sender authentication.

한편, 상기 클라이언트 인증값은 상기 세션정보와 상기 공유키를 이용하여 일방향 함수로 계산될 수 있다. The client authentication value may be calculated as a one-way function using the session information and the shared key.

상기 HTTP 응답은 상기 클라이언트가 HTTP 내용 중 일부를 암호화할 수 있도록 하는 암호 루틴을 포함하여 상기 클라이언트에 전송되되, 상기 클라이언트는 상기 암호 루틴에 따라 상기 공유키를 이용하여 상기 HTTP 내용 중 일부가 암호화된 HTTP 요청을 상기 서버에 전송하는 단계를 더 포함할 수 있다. The HTTP response is sent to the client including a cryptographic routine that allows the client to encrypt some of the HTTP content, wherein the client encrypts a portion of the HTTP content using the shared key according to the cryptographic routine. The method may further include transmitting an HTTP request to the server.

상기 세션정보는 난수일 수 있다.The session information may be a random number.

또는 상기 세션정보는 난수와 키 변형 인수를 포함할 수 있다. 상기 클라이언트 인증값은 상기 클라이언트에 저장된 상기 공유키 및 상기 키 변형 인수를 이용하여 계산한 클라이언트 비밀키와, 상기 HTTP 응답에 포함된 상기 난수를 인수로 하는 일방향 함수로 계산될 수 있다. Alternatively, the session information may include a random number and a key modification factor. The client authentication value may be calculated as a one-way function that takes a client secret key calculated using the shared key and the key modification factor stored in the client, and the random number included in the HTTP response.

한편, 상술한 사용자 세션 관리 방법은 컴퓨터에 의하여 수행될 수 있으며, 컴퓨터에서 실행하기 위한 프로그램을 기록하는 컴퓨터 판독 가능한 기록매체에 기록되어 클라이언트에서 수행될 수 있다. Meanwhile, the above-described user session management method may be performed by a computer, and may be recorded on a computer-readable recording medium for recording a program to be executed on the computer and executed by the client.

본 발명의 또 다른 측면에 따르면, 웹 환경에서 네트워크를 통해 연결된 클라이언트와 서버 간의 사용자 세션을 관리하는 시스템에 있어서, 상기 클라이언트와 상기 서버는 공유키를 공유하고, 상기 사용자 세션이 유효한 동안 상기 클라이언트로부터의 HTTP 요청이 시도-응답 프로토콜(challenge-response protocol) 중 응답(response) 과정에 해당하고, 상기 서버로부터의 HTTP 응답이 상기 시도-응답 프로토콜 중 시도(challenge) 과정에 해당하는 것을 특징으로 하는 사용자 세션 관리 시스템이 제공된다.According to another aspect of the present invention, in a system for managing a user session between a client and a server connected via a network in a web environment, the client and the server share a shared key, from the client while the user session is valid A user of an HTTP request corresponding to a challenge process among a challenge-response protocol, and an HTTP response from the server corresponds to a challenge process among the challenge-response protocols A session management system is provided.

여기서, 상기 서버는 상기 공유키를 이용하여 생성한 서버측 세션유지정보와, 상기 공유키를 이용하여 상기 클라이언트에서 생성한 상기 클라이언트측 세션유지정보-여기서, 상기 클라이언트측 세션유지정보는 상기 HTTP 요청에 포함됨-를 비교하여 상기 사용자 세션의 유효 여부를 결정할 수 있다. Here, the server is server-side session maintenance information generated using the shared key, and the client-side session maintenance information generated by the client using the shared key, wherein the client-side session maintenance information is the HTTP request Included in-may be compared to determine whether the user session is valid.

전술한 것 외의 다른 측면, 특징, 이점이 이하의 도면, 특허청구범위 및 발명의 상세한 설명으로부터 명확해질 것이다.Other aspects, features, and advantages other than those described above will become apparent from the following drawings, claims, and detailed description of the invention.

본 발명에 따른 사용자 세션 관리 방법 및 시스템, 이를 수행하는 프로그램이 기록된 기록매체는 시도-응답 방식의 인증 알고리즘을 HTTP 프로토콜에 적용하여 사용자의 세션 보호가 가능하다. A method and system for managing a user session according to the present invention and a recording medium on which a program for performing the same are recorded can protect a user's session by applying a challenge-response authentication algorithm to the HTTP protocol.

또한, 웹 브라우저에서 공유키를 저장하기 위하여 쿠키가 아닌 다른 저장 공간을 이용함으로써 평문 형태로 자동 전송되는 종래 쿠키의 단점 극복이 가능한 효과가 있다. In addition, by using a storage space other than the cookie to store the shared key in the web browser it is possible to overcome the disadvantage of the conventional cookie that is automatically transmitted in the form of plain text.

또한, HTTP에서 웹 서비스에 로그인한 사용자와 서버 사이의 채널을 시도-응답 방식의 인증 알고리즘을 이용하여 도청(sniffing), 침입(injection), 위조(forgery) 등의 공격으로부터 안전하게 보호할 수 있다.In addition, a channel between a user logged in to a web service and a server in HTTP can be secured from an attack such as sniffing, injection, and forgery using a challenge-response authentication algorithm.

또한, 액티브X 등의 신규 프로그램을 클라이언트에 배포하지 않고서도 사용자의 세션 보호가 가능하며, 클라이언트의 웹 브라우저가 서버와 계속 통신을 유지하지 않아도 된다. 그리고 상술한 과정을 통해 인증된 쿠키로 서버에서 제공하는 다양한 웹 서비스와 안전하게 세션 공유가 가능하다. In addition, users' sessions can be protected without distributing new programs such as ActiveX to the client, and the client's web browser does not have to maintain communication with the server. In addition, the session can be securely shared with various web services provided by the server using the authenticated cookie.

본 발명은 다양한 변환을 가할 수 있고 여러 가지 실시예를 가질 수 있는 바, 특정 실시예들을 도면에 예시하고 상세한 설명에 상세하게 설명하고자 한다. 그러나, 이는 본 발명을 특정한 실시 형태에 대해 한정하려는 것이 아니며, 본 발명의 사상 및 기술 범위에 포함되는 모든 변환, 균등물 내지 대체물을 포함하는 것으로 이해되어야 한다. 본 발명을 설명함에 있어서 관련된 공지 기술에 대한 구체적인 설명이 본 발명의 요지를 흐릴 수 있다고 판단되는 경우 그 상세한 설명을 생략한다.As the invention allows for various changes and numerous embodiments, particular embodiments will be illustrated in the drawings and described in detail in the written description. However, this is not intended to limit the present invention to specific embodiments, it should be understood to include all transformations, equivalents, and substitutes included in the spirit and scope of the present invention. In the following description of the present invention, if it is determined that the detailed description of the related known technology may obscure the gist of the present invention, the detailed description thereof will be omitted.

제1, 제2 등의 용어는 다양한 구성요소들을 설명하는데 사용될 수 있지만, 상기 구성요소들은 상기 용어들에 의해 한정되어서는 안 된다. 상기 용어들은 하나의 구성요소를 다른 구성요소로부터 구별하는 목적으로만 사용된다. Terms such as first and second may be used to describe various components, but the components should not be limited by the terms. The terms are used only for the purpose of distinguishing one component from another.

본 출원에서 사용한 용어는 단지 특정한 실시예를 설명하기 위해 사용된 것으로, 본 발명을 한정하려는 의도가 아니다. 단수의 표현은 문맥상 명백하게 다르게 뜻하지 않는 한, 복수의 표현을 포함한다. 본 출원에서, "포함하다" 또는 "가지다" 등의 용어는 명세서상에 기재된 특징, 숫자, 단계, 동작, 구성요소, 부품 또는 이들을 조합한 것이 존재함을 지정하려는 것이지, 하나 또는 그 이상의 다른 특징들이나 숫자, 단계, 동작, 구성요소, 부품 또는 이들을 조합한 것들의 존재 또는 부가 가능성을 미리 배제하지 않는 것으로 이해되어야 한다.The terminology used herein is for the purpose of describing particular example embodiments only and is not intended to be limiting of the present invention. Singular expressions include plural expressions unless the context clearly indicates otherwise. In this application, the terms "comprise" or "have" are intended to indicate that there is a feature, number, step, operation, component, part, or combination thereof described in the specification, and one or more other features. It is to be understood that the present invention does not exclude the possibility of the presence or the addition of numbers, steps, operations, components, components, or a combination thereof.

도 1은 본 발명에 적용되는 시도-응답 프로토콜(challenge-response protocol)의 인증 방법을 설명한 도면이다. 이하에서 비밀키는 클라이언트(1)가 클라이어트 인증값을 계산하고 서버(2)가 서버 인증값을 계산하기 위해 필요한 키이며, 공유키는 클라이언트(1)와 서버(2)가 최초 사용자 로그인 과정에서 공유하는 키를 의미한다.1 is a view for explaining the authentication method of the challenge-response protocol applied to the present invention. Hereinafter, the secret key is a key required for the client 1 to calculate the client authentication value and the server 2 to calculate the server authentication value, and the shared key is used by the client 1 and the server 2 during the initial user login process. Means a shared key.

클라이언트(1)와 서버(2) 사이의 비밀키인 K를 클라이언트(1)와 서버(2)가 서로 공유하고 있다(단계 S10). 여기서, 비밀키 K는 공유키에 해당한다. 공유키 K는 안전한 키 교환 프로토콜(예를 들어, PAKE(Password Authenticated Key Exchange) 등)을 이용하여 클라이언트(1)를 통한 서버(2)로의 사용자 로그인 과정에서 공유가능하다. The client 1 and the server 2 share K, which is a secret key between the client 1 and the server 2 (step S10). Here, the secret key K corresponds to the shared key. The shared key K can be shared during the user login process to the server 2 via the client 1 using a secure key exchange protocol (e.g., Password Authenticated Key Exchange (PAKE), etc.).

서버(2)는 난수 R1을 생성하고(단계 S11), 세션 등을 이용하여 난수 R1을 저장한다. 그리고 생성한 난수 R1을 클라이언트(1)에 전송한다(단계 S12). 난수 R1을 클라이언트(1)에 전송하는 과정이 시도(challenge) 과정에 해당한다. The server 2 generates a random number R1 (step S11) and stores the random number R1 using a session or the like. The generated random number R1 is transmitted to the client 1 (step S12). The process of transmitting the random number R1 to the client 1 corresponds to a challenge process.

클라이언트(1)는 서버(2)로부터 전송받은 난수 R1과 클라이언트(1)가 미리 저장하고 있었던 공유키 K를 이용하여 클라이언트 인증값 C를 계산한다(단계 S13). 난수 R1과 공유키 K를 이용하여 클라이언트 인증값 C를 계산하는 함수는 일방향 함수이다. 일방향 함수는 인수로부터 결과(함수값)를 구하는 것은 간단하지만, 결과로부터 인수를 구하는 것은 어려운 함수를 일컬으며, 이러한 일방향 함수로는 해쉬 함수, 유사 난수 함수 등이 포함된다. The client 1 calculates the client authentication value C using the random number R1 received from the server 2 and the shared key K previously stored by the client 1 (step S13). The function of calculating the client authentication value C using the random number R1 and the shared key K is a one-way function. One-way functions are simple to get the result (function value) from the argument, but it is difficult to get the argument from the result. Such one-way functions include hash functions, pseudorandom functions, and the like.

클라이언트(1)는 생성된 클라이언트 인증값 C를 서버(2)에 전송한다(단계 S14). 클라이언트 인증값 C를 서버(2)에 전송하는 과정이 응답(response) 과정에 해당한다. The client 1 transmits the generated client authentication value C to the server 2 (step S14). The process of transmitting the client authentication value C to the server 2 corresponds to the response process.

서버(2)는 단계 S11에서 난수 R1을 생성한 후 후술할 단계 S16 이전까지의 과정 중에 임의의 시점에서 난수 R1과 서버(2)가 미리 저장하고 있었던 공유키 K를 이용하여 서버 인증값 S를 계산한다(단계 S15). 난수 R1과 공유키 K를 이용하여 서버 인증값 S를 계산하는 함수는 일방향 함수이며, 클라이언트(1)에서 이용한 일방향 함수와 동일한 것이 바람직하다. The server 2 generates the server authentication value S using the random number R1 and the shared key K previously stored by the server 2 at any point in the process up to step S16, which will be described later, after generating the random number R1 in step S11. Calculate (step S15). The function of calculating the server authentication value S using the random number R1 and the shared key K is a one-way function, preferably the same as the one-way function used by the client 1.

서버(2)는 클라이언트(1)로부터 전송받은 클라이언트 인증값 C와, 서버(2) 내에서 생성한 서버 인증값 S를 비교한다(단계 S16). The server 2 compares the client authentication value C received from the client 1 with the server authentication value S generated in the server 2 (step S16).

비교 결과 클라이언트 인증값 C와 서버 인증값 S가 다른 경우에는 클라이언 트(1)가 가지고 있는 공유키 K가 서버(2)가 가지고 있는 공유키 K와 다른 것으로 판단하여 클라이언트(1)의 인증에 실패한 것으로 간주하고(단계 S17), 사용자 세션이 유효하지 않으므로 사용자 세션을 삭제한다. As a result of the comparison, when the client authentication value C and the server authentication value S are different, it is determined that the shared key K of the client 1 is different from the shared key K of the server 2, and thus the authentication of the client 1 fails. (Step S17), the user session is not valid and the user session is deleted.

비교 결과 클라이언트 인증값 C와 서버 인증값 S가 동일한 경우에는 클라이언트(1)가 가지고 있는 공유키 K가 서버(2)가 가지고 있는 공유키 K와 동일한 것으로 판단하여 클라이언트(1)의 인증에 성공한 것으로 간주하고(단계 S18), 사용자 세션의 유효를 유지시킨다. 그리고 새로운 난수 R2를 생성한다(단계 S19). 그리고 상술한 단계 S12 내지 S16에 설명한 시도-응답 과정에 따라 클라이언트(1)의 인증을 반복하게 된다. As a result of the comparison, if the client authentication value C and the server authentication value S are the same, it is determined that the shared key K of the client 1 is the same as the shared key K of the server 2 and the authentication of the client 1 is successful. (Step S18), the user session is maintained valid. Then, a new random number R2 is generated (step S19). The authentication of the client 1 is repeated according to the challenge-response process described in the above-described steps S12 to S16.

본 발명에서는 상술한 시도-응답 프로토콜을 HTTP 프로토콜에 적용함으로써 웹 환경에서 안전한 사용자 세션 관리 방법 및 시스템을 제공하고자 한다. The present invention provides a method and system for secure user session management in a web environment by applying the above-described challenge-response protocol to the HTTP protocol.

도 2는 본 발명의 일 실시예에 따른 서버에 포함되는 세션 관리 모듈의 블록구성도이고, 도 3은 본 발명의 일 실시예에 따른 안전한 사용자 세션 관리 방법, HTTP 요청의 송신자 인증 프로토콜을 설명한 도면이다. 2 is a block diagram illustrating a session management module included in a server according to an embodiment of the present invention, and FIG. 3 is a diagram illustrating a secure user session management method and a sender authentication protocol of an HTTP request according to an embodiment of the present invention. to be.

도 2를 참조하면, 세션 관리 모듈(20), 난수 생성부(21), 인증값 산출부(22), 인증값 비교부(23), 인증 관리부(24)가 도시되어 있다. 2, a session management module 20, a random number generator 21, an authentication value calculator 22, an authentication value comparison unit 23, and an authentication manager 24 are illustrated.

세션 관리 모듈(20)은 웹 서비스를 제공하는 서버(2)에 포함된다. 세션 관리 모듈(20)은 클라이언트(1)로부터의 HTTP 요청에 대한 송신자 인증을 위해 세션을 관리한다. The session management module 20 is included in the server 2 that provides a web service. The session management module 20 manages sessions for sender authentication for HTTP requests from client 1.

난수 생성부(21)는 클라이언트(1)와 공유하기 위한 난수를 생성한다. The random number generator 21 generates a random number for sharing with the client 1.

인증값 산출부(22)는 생성된 난수와 미리 저장되어 있는 공유키 등을 인수로 하는 미리 정해진 함수로 계산한 결과값인 서버 인증값을 산출한다. The authentication value calculation unit 22 calculates a server authentication value which is a result obtained by calculating a predetermined function using the generated random number and a pre-stored shared key as an argument.

인증값 비교부(23)는 인증값 산출부(22)에서 계산한 서버 인증값과 클라이언트(1)로부터 전송되는 클라이언트 인증값(클라이언트(1)에서 난수와 공유키 등을 인수로 하는 미리 정해진 함수로 계산한 결과값)을 비교한다. The authentication value comparison unit 23 takes a server authentication value calculated by the authentication value calculation unit 22 and a client authentication value transmitted from the client 1 (the predetermined function using the random number and the shared key in the client 1 as an argument). Compare the result calculated with).

인증 관리부(24)는 비교 결과에 따라 HTTP 요청을 한 클라이언트(1)의 송신자 인증 성공 또는 인증 실패가 결정된다. 인증이 실패한 경우 부적합한 클라이언트(1)로부터의 HTTP 요청(예를 들어, 공격자의 HTTP 요청 등)으로 판단하고 세션을 삭제시킨다. 인증이 성공한 경우 적합한 클라이언트(1)로부터의 HTTP 요청으로 판단하고 세션을 유지시킨다. The authentication manager 24 determines the sender authentication success or the authentication failure of the client 1 that made the HTTP request according to the comparison result. If authentication fails, it is determined as an HTTP request (for example, an HTTP request of an attacker) from the inappropriate client 1, and the session is deleted. If authentication succeeds, it is determined as an HTTP request from the appropriate client 1 and the session is maintained.

이하에서는 상술한 세션 관리 모듈(20)의 동작 및 웹 환경에서 네트워크로 연결된 클라이언트(1)와 서버(2)를 포함하는 본 발명에 따른 사용자 세션 관리 시스템에서의 HTTP 요청 및 HTTP 응답 흐름에 대하여 도 3을 참조하여 상세히 설명하기로 한다. 본 발명의 이해와 설명의 편의를 위하여 세션 관리 모듈(20)은 서버(2)로 표현하기로 한다. Hereinafter, the operation of the above-described session management module 20 and the flow of HTTP requests and HTTP responses in the user session management system according to the present invention including a client 1 and a server 2 connected to a network in a web environment. It will be described in detail with reference to 3. For convenience of understanding and explanation of the present invention, the session management module 20 will be referred to as a server 2.

클라이언트(1)와 서버(2) 사이의 비밀키 K를 클라이언트(1)와 서버(2)가 서로 공유하고 있다(단계 S30). 즉, 비밀키 K는 공유키에 해당한다. 공유키 K는 안전한 키 교환 프로토콜(예를 들어, PAKE 등)를 이용하여 클라이언트(1)를 통한 서버(2)로의 웹 서비스의 사용자 로그인 과정에서 공유가능하다. The secret key K between the client 1 and the server 2 is shared between the client 1 and the server 2 (step S30). That is, the secret key K corresponds to the shared key. The shared key K can be shared during the user login process of the web service via the client 1 to the server 2 using a secure key exchange protocol (e.g., PAKE, etc.).

공유키 K는 클라이언트(1)의 로그인 단계에서 교환되어 로그아웃될 때까지 웹 브라우저에 저장되어 있어야 한다. 그리고 웹 페이지가 바뀌더라도 지속적으로 유지되어야 한다. The shared key K must be stored in the web browser until it is exchanged and logged out at the login stage of the client 1. And even if the web page changes, it must be maintained.

이 경우 공유키를 쿠키에 저장하는 경우 클라이언트(1)로부터의 HTTP 요청에 쿠키가 포함되어 네트워크로 전송되므로 공유키가 그대로 노출되는 문제점이 있다. In this case, when the shared key is stored in a cookie, the cookie is included in the HTTP request from the client 1 and transmitted to the network, thereby exposing the shared key as it is.

따라서, 클라이언트(1)는 공유키 K를 쿠키가 아닌 별도의 저장 공간에 저장한다. 웹 브라우저의 문서 객체 모델(DOM: Document Object Model)의 윈도우 객체의 속성 중 윈도우 이름(window.name), 플래시(Flash)의 지역 공유 객체(LSO: Local Shared Object), 액티브X 등의 저장 공간이 이용될 수 있다. 이러한 저장 공간에 대해서는 추후 상세히 설명하기로 한다. Therefore, the client 1 stores the shared key K in a separate storage space rather than a cookie. Among the properties of the window object of the document object model (DOM) of the web browser, the storage space of the window name (window.name), local shared object (LSO) of Flash, ActiveX, etc. Can be used. This storage space will be described later in detail.

클라이언트(1)로부터 HTTP 요청(HTTP request)이 전송되면(단계 S31), 서버(2)는 다음과 같이 동작한다. When an HTTP request is transmitted from the client 1 (step S31), the server 2 operates as follows.

서버(2)는 난수 R을 생성한다(단계 S32). 이와 관련된 의사 코드(Pseudo code)는 하기와 같다. The server 2 generates a random number R (step S32). Pseudo code associated with this is as follows.

R = random()R = random ()

서버(2)는 난수 R과 공유키 K를 이용하여 미리 정해진 함수로 계산한 결과값인 서버 인증값 S를 산출한다(단계 S37). 여기서, 사용자 식별정보인 ID 등이 미리 정해진 함수의 인수로 더 포함될 수 있다. 이와 관련된 의사 코드는 하기와 같다.The server 2 calculates a server authentication value S which is a result calculated by a predetermined function using the random number R and the shared key K (step S37). Here, ID, which is user identification information, may be further included as an argument of a predetermined function. The pseudo code related to this is as follows.

S = Func(K, R, ID, …)S = Func (K, R, ID,…)

여기서, 미리 정해진 함수는 일방향 함수인 것이 바람직하다. 일방향 함수는 인수로부터 결과(함수값)를 구하는 것은 간단하지만, 결과로부터 인수를 구하는 것은 어려운 함수를 일컬으며, 이러한 일방향 함수로는 해쉬 함수, 유사 난수 함수 등이 포함된다. Here, the predetermined function is preferably a one-way function. One-way functions are simple to get the result (function value) from the argument, but it is difficult to get the argument from the result. Such one-way functions include hash functions, pseudorandom functions, and the like.

서버(2)는 공유키 K, 난수 R, 서버 인증값 S를 웹 어플리케이션에서 제공하는 세션 또는 데이터베이스에 저장한다. 이와 관련된 의사 코드는 하기와 같다. The server 2 stores the shared key K, the random number R, and the server authentication value S in a session or database provided by the web application. The pseudo code related to this is as follows.

Session = {K, R, S}Session = {K, R, S}

상술한 단계 S37은 후술한 단계 S32 이후 단계 S38 이전에 임의의 시점에서 서버(2)에서 수행되면 충분하다. It is sufficient that step S37 described above is performed at the server 2 at any point in time after step S32 and before step S38 described later.

서버(2)는 HTTP 응답(HTTP response)을 통해 단계 S32에서 생성된 난수 R을 클라이언트(1)에 전송한다(단계 S33). 난수 R은 세션정보에 해당한다. 여기서, 세션정보는 사용자 세션 인증을 위해 서버(2)가 클라이언트(1)에 제공하는 정보를 의미한다. The server 2 transmits the random number R generated in step S32 to the client 1 via an HTTP response (step S33). The random number R corresponds to session information. Here, the session information refers to information that the server 2 provides to the client 1 for user session authentication.

클라이언트(1)는 전송받은 난수 R과, 소정의 저장 공간에 저장된 공유키 K를 이용하여 미리 정해진 함수로 계산한 결과값인 클라이언트 인증값 C를 산출한다(단계 S34). 여기서, 사용자 식별정보인 ID 등이 미리 정해진 함수의 인수로 더 포함될 수 있다. 여기서, 미리 정해진 함수는 단계 S37에서 서버(2)가 이용한 일방향 함수와 동일해야 한다. The client 1 calculates the client authentication value C, which is a result of the calculation using a predetermined function, using the received random number R and the shared key K stored in the predetermined storage space (step S34). Here, ID, which is user identification information, may be further included as an argument of a predetermined function. Here, the predetermined function must be the same as the one-way function used by the server 2 in step S37.

이후 클라이언트(1)는 산출된 클라이언트 인증값 C를 쿠키에 저장한다(단계 S35). 이와 관련된 의사 코드는 하기와 같다. The client 1 then stores the calculated client authentication value C in a cookie (step S35). The pseudo code related to this is as follows.

setCookie(C = Func(K, R, ID, …))setCookie (C = Func (K, R, ID,…))

클라이언트(1)가 HTTP 요청을 하는 경우 클라이언트 인증값 C를 저장하고 있는 쿠키는 자동으로 포함되어 서버(2)로 전송된다(단계 S36). When the client 1 makes an HTTP request, the cookie that stores the client authentication value C is automatically included and sent to the server 2 (step S36).

서버(2)는 쿠키에 포함된 클라이언트 인증값 C와 단계 S37에서 산출된 서버 인증값 S를 비교한다(단계 S38). 비교 결과 두 인증값이 다른 경우 단계 S39로 진행하고, 동일한 경우 단계 S40으로 진행한다. The server 2 compares the client authentication value C included in the cookie with the server authentication value S calculated in step S37 (step S38). The comparison proceeds to step S39 if the two authentication values are different, and if so, to step S40.

단계 S39에서, 두 인증값이 다르므로 서버(2)는 클라이언트(1)의 송신자 인증이 실패한 것으로 간주하고 서버(2)에 저장된 서버측 세션유지정보(난수 R, 공유키 K 등)를 삭제하고 세션을 삭제한다. 이와 관련된 의사 코드는 하기와 같다. In step S39, since the two authentication values are different, the server 2 regards the sender authentication of the client 1 as failed and deletes the server-side session maintenance information (random number R, shared key K, etc.) stored in the server 2, and Delete the session. The pseudo code related to this is as follows.

Session destroy()Session destroy ()

그리고 클라이언트(1)에 저장된 클라이언트측 세션유지정보(공유키 K와 난수 R, 쿠키 등)가 모두 NULL로 설정되도록 하는 클라이언트측 스크립트(Client Side Script), 플래시 또는 액티브X를 클라이언트(1)에 전송한다. 이 과정에서 사용자는 로그아웃된다. Then, the client side script (Flash) or ActiveX is transmitted to the client 1 so that all client side session maintenance information (shared key K, random number R, cookie, etc.) stored in the client 1 is set to NULL. do. In this process, the user is logged out.

단계 S40에서, 두 인증값이 동일하므로 서버(2)는 클라이언트(1)의 송신자 인증이 성공한 것으로 간주하고, 새로운 난수 R을 생성한다(단계 S41). 그리고 클라이언트(1)가 HTTP 요청을 통해 요청한 서비스에 대한 HTTP 응답에 새로 생성된 난수 R을 첨부하여 클라이언트(1)에 전송한다(단계 S42). 이후 서버(2)는 다른 HTTP 요청을 받게 되면 단계 S38 이하의 과정을 반복하게 된다. In step S40, since the two authentication values are the same, the server 2 considers the sender authentication of the client 1 to be successful, and generates a new random number R (step S41). Then, the client 1 attaches the newly generated random number R to the HTTP response to the service requested through the HTTP request and transmits it to the client 1 (step S42). Thereafter, when the server 2 receives another HTTP request, the server 2 repeats the process of step S38 or less.

클라이언트(1)는 단계 S30에서 교환한 공유키 K를 쿠키가 아닌 별도의 저장 공간에 저장한다. 웹 브라우저의 문서 객체 모델(DOM: Document Object Model)의 윈도우 객체의 속성 중 윈도우 이름(window.name), 플래시(Flash)의 지역 공유 객체(LSO: Local Shared Object), 액티브X 등의 저장 공간이 이용될 수 있다. The client 1 stores the shared key K exchanged in step S30 in a separate storage space rather than a cookie. Among the properties of the window object of the document object model (DOM) of the web browser, the storage space of the window name (window.name), local shared object (LSO) of Flash, ActiveX, etc. Can be used.

일 실시예로, 클라이언트(1)에서의 저장 공간은 웹 브라우저의 문서 객체 모델(DOM: Document Object Model)의 윈도우 객체의 속성 중 윈도우 이름(window.name)일 수 있다. 여기서, 문서 객체 모델은 웹 브라우저를 통한 확장성 생성 언어(XML) 문서의 상호 연동을 위한 객체 기반의 문서 모델을 의미한다. 플랫폼과 언어 면에서 중립적인 인터페이스로서 프로그램과 스크립트에 의한 문서의 내용, 구조, 종류의 동적인 접근과 변경이 가능하며, 스크립트나 프로그램 언어에 웹 페이지를 연결해 준다. 웹 페이지를 조작, 생성하기 위해 사용되는 속성(property), 방법(method) 및 이벤트(event)가 객체를 구성하는데, 이러한 객체들은 대부분의 웹 브라우저에서 스크립트 언어를 통해 접근할 수 있다.In one embodiment, the storage space in the client 1 may be a window name (window.name) among the properties of the window object of the document object model (DOM) of the web browser. Here, the document object model refers to an object-based document model for interworking an extensible generation language (XML) document through a web browser. It is a platform- and language-neutral interface that allows programs and scripts to dynamically access and change the content, structure, and type of documents, and links web pages to scripts or programming languages. The properties, methods, and events used to manipulate and create web pages make up objects, which can be accessed through scripting languages in most web browsers.

윈도우 이름(window.name)의 원래 목적은 각각의 브라우저(또는 탭)마다 이름을 부여하고 이 이름을 통해서 브라우저 간에 접근이 가능하도록 하는 것이었다. 브라우저 내의 페이지가 바뀌더라도 브라우저의 이름은 바뀌지 않기 때문에 최근엔 이를 이용하여 페이지 사이에 데이터를 전달하는 용도로 사용하고 있다. 윈도우 이름은 쓰기 가능한 크기도 정해져 있지 않아서 원하는 데이터를 크기 제한 없이 저장할 수 있다는 장점이 있다. The original purpose of the window name (window.name) was to give each browser (or tab) a name and make it accessible between browsers. Since the name of the browser does not change even if the page in the browser is changed, it is recently used to transfer data between pages. The name of the window is not fixed, and the advantage is that you can store the data you want without limiting its size.

다른 실시예로, 클라이언트(1)에서의 저장 공간은 플래시의 지역 공유 객체(LSO: Local Shared Object)일 수 있다. 지역 공유 객체는 플래시 플레이어에서 사용되는 쿠키와 유사한 데이터 엔티티(cookie-like data entity)이다. 플레시 플레이어에서 구동되는 어플리케이션은 스트링(string)이나 숫자(number) 같은 기본 데이터 타입(basic data type)으로 구성되거나 더 복잡한 객체로 구성되는 데이터를 저장(store)하고 검색(retrieve)할 수 있다. 플래시의 지역 공유 객체는 플래시 플러그인(plug-in)이 설치되어 있다면 이용할 수 있는 공간이다. 변수명이 윈도우 이름(window.name)으로 지정된 일 실시예와는 다르게 변수명을 원하는 것으로 설정할 수 있고 쿠키와 같이 도메인별로 데이터를 관리할 수 있기 때문에 보안문제가 어느 정도 완화될 수 있다. 지역 공유 객체의 기본 크기는 100kB이다.In another embodiment, the storage space at the client 1 may be a Local Shared Object (LSO) in Flash. Local shared objects are cookie-like data entities used in Flash Player. Applications running on Flash Player can store and retrieve data consisting of basic data types, such as strings or numbers, or of more complex objects. Flash's local shared objects are available if you have a flash plug-in installed. Unlike the embodiment in which the variable name is designated as the window name (window.name), the security name can be alleviated to some extent because the variable name can be set as desired and data can be managed for each domain such as a cookie. The default size of a local shared object is 100 kB.

또 다른 실시예로, 클라이언트(1)는 액티브X를 이용하여 공유키 K를 저장할 수도 있다. 액티브X는 익스플로러의 경우 이용할 수 있는 플러그인으로, 컴파일된 프로그램을 사용자의 컴퓨터에 설치하여 클라이언트의 자원을 보다 많이 이용할 수 있다는 장점이 있다. 액티브X를 이용할 경우 제작자가 설정한 위치에 데이터를 저장하고 읽을 수 있다. 액티브X와 관련된 기술로 저장 공간의 역할을 할 수 있는 것은 액티브X 도큐먼트, 액티브X 스크립팅 등이 있다. 액티브X 도큐먼트는 HTML과는 무관하게 작성된 것으로, MS워드나 엑셀 파일 등을 의미한다. 액티브 스크립팅은 액티브X 컨트롤이나 자바 애플릿에 포함시킬 수 있는 스크립트 언어로, J스크립트나 VB스크립트가 대표적이다. In another embodiment, the client 1 may store the shared key K using ActiveX. ActiveX is a plug-in that can be used in Explorer, which has the advantage of installing a compiled program on the user's computer to make more use of the client's resources. With ActiveX, you can save and read data in the location set by the author. ActiveX-related technologies can serve as storage spaces, such as ActiveX documents and ActiveX scripting. ActiveX documents are written without regard to HTML, meaning MS Word or Excel files. Active scripting is a scripting language that can be included in ActiveX controls or Java applets, such as JScript or VBScript.

이러한 저장 공간에 비밀키인 공유키를 저장하고 있는 경우 비밀키가 외부로 노출되는 경우 안전한 세션관리가 어려울 수 있다. 예를 들어, 윈도우 이름은 쓰기 가능한 크기도 정해져 있지 않아서 원하는 데이터를 크기 제한 없이 저장할 수 있다는 장점이 있지만 다른 서비스로 이동하여도 값이 바뀌지 않기 때문에 여기에 비밀키를 저장한다면 보안상에 결점이 발생할 수 있다. 여기서 생길 수 있는 보안 문제의 해결 방법은 비밀키 자체를 저장하지 않고 이를 변형 또는 암호화한 것을 저장하여 윈도우 이름에 저장된 값이 노출되더라도 비밀키가 직접적으로 노출되지 않도록 하는 것이다. In the case where the shared key, which is a secret key, is stored in such a storage space, it may be difficult to secure session management when the secret key is exposed to the outside. For example, the window name has the advantage of being able to store the desired data without any size limit because the window name is not fixed, but the value does not change even when moving to another service. Can be. The solution to this security problem is to store the modified or encrypted version of the private key without storing it, so that the private key is not directly exposed even if the value stored in the window name is exposed.

도 3을 참조하여 상술한 내용에서는 비밀키와 공유키가 동일한 경우이며, 이하에서는 비밀키와 공유키가 다른 경우를 중심으로 도 4를 참조하여 상세히 설명하기로 한다. In the above description with reference to FIG. 3, the case where the secret key and the shared key are the same will be described below in detail with reference to FIG. 4.

도 4는 본 발명의 다른 실시예에 따른 안전한 사용자 세션 관리 방법, 키 보호모드에서의 HTTP 요청의 송신자 인증 프로토콜을 설명한 도면이다. 4 is a diagram illustrating a secure user session management method and a sender authentication protocol of an HTTP request in key protection mode according to another embodiment of the present invention.

즉, 키 보호모드는 공유키가 노출되더라도 비밀키는 노출되지 않아 HTTP 요청의 송신자 인증이 가능한 경우를 의미하며, 도 3을 참조하여 설명한 것과는 달리 공유키와 비밀키가 다른 값을 가진다. That is, the key protection mode means that the secret key is not exposed even if the shared key is exposed, so that the sender authentication of the HTTP request is possible. Unlike the description with reference to FIG. 3, the shared key has a different value.

클라이언트(1)와 서버(2) 사이의 공유키인 K를 클라이언트(1)와 서버(2)가 서로 공유하고 있다(단계 S50). 공유키 K는 안전한 키 교환 프로토콜(예를 들어, PAKE 등)를 이용하여 클라이언트(1)를 통한 서버(2)로의 웹 서비스의 사용자 로그인 과정에서 공유가능하다. The client 1 and the server 2 share K, which is a shared key between the client 1 and the server 2 (step S50). The shared key K can be shared during the user login process of the web service via the client 1 to the server 2 using a secure key exchange protocol (e.g., PAKE, etc.).

공유키 K는 클라이언트(1)의 로그인 단계에서 교환되어 로그아웃될 때까지 웹 브라우저에 저장되어 있어야 한다. 그리고 웹 페이지가 바뀌더라도 지속적으로 유지되어야 한다. The shared key K must be stored in the web browser until it is exchanged and logged out at the login stage of the client 1. And even if the web page changes, it must be maintained.

이 경우 공유키를 쿠키에 저장하는 경우 클라이언트(1)로부터의 HTTP 요청에 쿠키가 포함되어 네트워크로 전송되므로 공유키가 그대로 노출되는 문제점이 있다. In this case, when the shared key is stored in a cookie, the cookie is included in the HTTP request from the client 1 and transmitted to the network, thereby exposing the shared key as it is.

따라서, 클라이언트(1)는 공유키 K를 쿠키가 아닌 별도의 저장 공간에 저장한다. 웹 브라우저의 문서 객체 모델(DOM)의 윈도우 객체의 속성 중 윈도우 이름(window.name), 플래시의 지역 공유 객체(LSO), 액티브X 등의 저장 공간이 이용될 수 있다. 이에 대해서는 앞서 설명하였는바 상세한 설명은 생략하기로 한다. Therefore, the client 1 stores the shared key K in a separate storage space rather than a cookie. Among the properties of the window object of the document object model (DOM) of the web browser, a storage space such as a window name (window.name), a local shared object (LSO) of Flash, ActiveX, or the like may be used. As described above, the detailed description will be omitted.

여기서, 공유키 K는 키 보호모드에 적용하기 위하여 하기의 수학식 1과 같은 특징을 가진다. Here, the shared key K has the characteristics as shown in Equation 1 below to apply to the key protection mode.

K = ① Func1(K1, K2) or ② K1K = ① Func1 (K1, K2) or ② K1

Func2(K, K2) = K'Func2 (K, K2) = K '

K' = ① K1 or ② K3K '= ① K1 or ② K3

여기서, K는 공유키, K'는 비밀키, Func1은 클라이언트(1)에 저장된 값을 통해 비밀키가 직접적으로 노출되지 않도록 키 변형 인수 K2를 이용하여 키를 변형시키는 키 변형 함수, Func2는 공유키 K로부터 키 변형 인수 K2를 이용하여 비밀키 K2를 생성해내는 비밀키 생성 함수이다.Here, K is a shared key, K 'is a secret key, Func1 is a key modification function that modifies a key using the key modification factor K2 so that the secret key is not directly exposed through a value stored in the client 1, and Func2 is shared. Secret key generation function that generates secret key K2 from key K using key transformation argument K2.

클라이언트(1)는 공유키 K만을 저장하고 있으며, 서버(2)는 공유키 K와 키 변형 인수 K2를 저장하고 있다. 이 경우 클라이언트(1)에 저장된 공유키 K 및/또는 키 변형 인수 K2가 외부에 노출되더라도 공유키 K와 키 변형 인수 K2를 이용하여 클라이언트 비밀키 K'를 생성해내므로, 비밀키의 보호가 가능하게 된다. The client 1 stores only the shared key K, and the server 2 stores the shared key K and the key modification factor K2. In this case, even if the shared key K and / or key modification factor K2 stored in the client 1 is exposed to the outside, the client secret key K 'is generated using the shared key K and the key modification factor K2, so that the secret key can be protected. Done.

제1 실시예(①)에 따르면, K1이 비밀키이다. According to the first embodiment (1), K1 is a secret key.

비밀키 K1이 노출되지 않도록 키 변형 함수 Func1과 키 변형 인수 K2를 이용하여 변형된 공유키 K를 클라이언트(1)와 서버(2)가 공유한다. 여기서, 비밀키 생성 함수 Func2는 키 변형 함수 Func1을 통해 변형된 키 K로부터 비밀키 K1을 복구해내는 함수이다. The client 1 and the server 2 share the modified shared key K using the key modification function Func1 and the key modification factor K2 so that the secret key K1 is not exposed. Here, the secret key generation function Func2 is a function for recovering the secret key K1 from the modified key K through the key transformation function Func1.

따라서, 클라이언트(1)는 공유키 K, 키 변형 인수 K2를 비밀키 생성 함수 Func2로 계산한 결과값인 클라이언트 비밀키 K', 즉 K1을 계산하고, 이를 송신자 인증을 위한 클라이언트측 세션유지정보 생성에 이용한다. 그리고 서버(2)는 공유키 K, 키 변형 인수 K2를 비밀키 생성 함수 Func2로 계산한 결과값인 서버 비밀키 K', 즉 K1을 계산하고, 이를 송신자 인증을 위한 서버측 세션유지정보 생성에 이용한다.Accordingly, the client 1 calculates the client secret key K ', ie, K1, which is the result of calculating the shared key K and the key modification factor K2 by the secret key generation function Func2, and generates the client side session maintenance information for sender authentication. We use for. The server 2 calculates the server secret key K ', ie, K1, which is the result of calculating the shared key K and the key modification factor K2 by the secret key generation function Func2, and generates the server side session maintenance information for the sender authentication. I use it.

제2 실시예(②)에 따르면, K1이 공유키이다. According to the second embodiment (2), K1 is the shared key.

공유키 K가 K1인 경우 비밀키 생성 함수 Func2는 K1과 키 변형 인수 K2를 인수로 하여 새로운 결과값인 K3를 비밀키로 생성해낸다. 따라서, 클라이언트(1)는 공유키 K1, 키 변형 인수 K2를 비밀키 생성 함수 Func2로 계산한 결과값인 클라이언트 비밀키 K', 즉 K3를 계산하고, 이를 송신자 인증을 위한 클라이언트측 세션유지정보 생성에 이용한다. 그리고 서버(2)는 공유키 K1, 키 변형 인수 K2를 비밀키 생성 함수 Func2로 계산한 결과값인 서버 비밀키 K', 즉 K3를 계산하고, 이를 송신자 인증을 위한 서버측 세션유지정보 생성에 이용한다.When the shared key K is K1, the secret key generation function Func2 generates a new result, K3, as a secret key using K1 and the key modification factor K2 as arguments. Accordingly, the client 1 calculates the client secret key K ', that is, K3, which is the result of calculating the shared key K1 and the key modification factor K2 by the secret key generation function Func2, and generates the client side session maintenance information for sender authentication. We use for. The server 2 calculates the server secret key K ', that is, K3, which is the result of calculating the shared key K1 and the key modification factor K2 by the secret key generation function Func2, and generates the server side session maintenance information for sender authentication. I use it.

단계 S50을 통해 서버(2)와 클라이언트(1)는 안전한 키 교환 프로토콜을 통해 공유키 K를 공유함을 가정하고 이하 송신자 인증 방법을 설명하기로 한다. In step S50, it is assumed that the server 2 and the client 1 share the shared key K through a secure key exchange protocol, and the sender authentication method will be described below.

서버(2)는 클라이언트(1)로부터의 HTTP 요청(단계 S51)을 전송받고, 서버(2)는 난수 R을 생성한다(단계 S52). 이와 관련된 의사 코드는 하기와 같다. The server 2 receives the HTTP request (step S51) from the client 1, and the server 2 generates a random number R (step S52). The pseudo code related to this is as follows.

R = random()R = random ()

서버(2)는 난수 R과 서버 비밀키 K'를 이용하여 미리 정해진 함수로 계산한 결과값인 서버 인증값 S를 산출한다(단계 S58). 여기서, 서버 비밀키 K'는 서버(2)가 미리 공유키 K와 키 변형 인수 K2를 인수로 하여 비밀키 생성 함수 Func2로 계산한 결과값이다. The server 2 calculates the server authentication value S, which is a result calculated by the predetermined function using the random number R and the server secret key K '(step S58). Here, the server secret key K 'is a result of the server 2 previously calculating the secret key generation function Func2 using the shared key K and the key modification factor K2 as arguments.

여기서, 사용자 식별정보인 ID 등이 미리 정해진 함수의 인수로 더 포함될 수 있다. 이와 관련된 의사 코드는 하기와 같다.Here, ID, which is user identification information, may be further included as an argument of a predetermined function. The pseudo code related to this is as follows.

S = Func(K', R, ID, …)S = Func (K ', R, ID,…)

여기서, 미리 정해진 함수는 일방향 함수인 것이 바람직하다. 이러한 일방향 함수로는 해쉬 함수, 유사 난수 함수 등이 포함된다. Here, the predetermined function is preferably a one-way function. Such one-way functions include hash functions and pseudorandom functions.

서버(2)는 공유키 K, 키 변형 인수 K2, 난수 R, 서버 인증값 S를 웹 어플리케이션에서 제공하는 세션 또는 데이터베이스에 저장한다. 이와 관련된 의사 코드는 하기와 같다. The server 2 stores the shared key K, the key modification factor K2, the random number R, and the server authentication value S in a session or database provided by the web application. The pseudo code related to this is as follows.

Session = {K, K2, R, S}Session = {K, K2, R, S}

상술한 단계 S58은 후술한 단계 S52 이후 단계 S59 이전에 임의의 시점에서 서버(2)에서 수행되면 충분하다. It is sufficient that step S58 described above is performed at the server 2 at any point in time after step S52 and before step S59 described later.

서버(2)는 HTTP 응답을 통해 단계 S52에서 생성된 난수 R과 키 변형 인수 K2를 클라이언트(1)에 전송한다(단계 S53). 난수 R과 키 변형 인수 K2는 세션정보에 해당한다. 여기서, 세션정보는 사용자 세션 인증을 위해 서버(2)가 클라이언트(1)에 제공하는 정보를 의미한다.The server 2 transmits the random number R and the key modification factor K2 generated in step S52 to the client 1 through the HTTP response (step S53). The random number R and the key modification factor K2 correspond to session information. Here, the session information refers to information that the server 2 provides to the client 1 for user session authentication.

이 경우 HTTP 응답에는 클라이언트(1)에서 공유키 K와 키 변형 인수 K2를 이용하여 클라이언트 비밀키 K'를 계산하고, 클라이언트 비밀키 K'를 이용하여 클라이언트측 세션유지정보인 클라이언트 인증값 C를 계산하며, 산출된 클라이언트 인증값 C를 쿠키에 저장하도록 하는 실행코드(예를 들어, 자바스크립트 등)가 더 포함될 수 있다. In this case, in the HTTP response, the client 1 calculates the client secret key K 'using the shared key K and the key modification factor K2, and calculates the client authentication value C, which is client-side session maintenance information, using the client secret key K'. In addition, execution code (for example, JavaScript) may be further included to store the calculated client authentication value C in a cookie.

클라이언트(1)는 전송받은 키 변형 인수 K2와 소정의 저장 공간에 저장된 공유키 K를 이용하여 비밀키 생성 함수 Func2로 계산한 클라이언트 비밀키 K'를 산출한다(단계 S54). The client 1 calculates the client secret key K 'calculated by the secret key generation function Func2 using the received key modification factor K2 and the shared key K stored in the predetermined storage space (step S54).

이후 클라이언트(1)는 전송받은 난수 R과, 단계 S54에서 산출된 클라이언트 비밀키 K'를 이용하여 미리 정해진 함수로 계산한 결과값, 즉 클라이언트측 세션유지정보인 클라이언트 인증값 C를 산출한다(단계 S55). 여기서, 사용자 식별정보인 ID 등이 미리 정해진 함수의 인수로 더 포함될 수 있다. 여기서, 미리 정해진 함수는 단계 S58에서 서버(2)가 이용한 일방향 함수와 동일해야 한다. After that, the client 1 calculates a result calculated by a predetermined function using the received random number R and the client secret key K 'calculated in step S54, that is, the client authentication value C which is client-side session maintenance information (step S54). S55). Here, ID, which is user identification information, may be further included as an argument of a predetermined function. Here, the predetermined function must be the same as the one-way function used by the server 2 in step S58.

이후 클라이언트(1)는 산출된 클라이언트 인증값 C를 쿠키에 저장한다(단계 S56). 이와 관련된 의사 코드는 하기와 같다. The client 1 then stores the calculated client authentication value C in a cookie (step S56). The pseudo code related to this is as follows.

setCookie(C = Func(K', R, ID, …))setCookie (C = Func (K ', R, ID,…))

여기서, 클라이언트 인증값 C를 쿠키에 저장한 직후에 공유키 K를 제외한 나머지는 모두 삭제하여 외부로 노출되지 않도록 한다. Here, immediately after storing the client authentication value C in the cookie, all but the shared key K is deleted to prevent exposure to the outside.

클라이언트(1)가 인증이 필요한 HTTP 요청을 하는 경우 새로운 클라이언트측 세션유지정보가 포함되어 서버(2)로 전송된다. 즉, 클라이언트 인증값 C를 저장하고 있는 쿠키가 자동으로 포함되어 서버(2)로 전송된다(단계 S57). When the client 1 makes an HTTP request requiring authentication, new client side session maintenance information is included and transmitted to the server 2. That is, the cookie storing the client authentication value C is automatically included and transmitted to the server 2 (step S57).

서버(2)는 쿠키에 포함된 클라이언트 인증값 C와 단계 S58에서 산출된 서버 인증값 S를 비교한다(단계 S59). 비교 결과 두 인증값이 다른 경우 단계 S60으로 진행하고, 동일한 경우 단계 S61로 진행한다. The server 2 compares the client authentication value C included in the cookie with the server authentication value S calculated in step S58 (step S59). The comparison proceeds to step S60 if the two authentication values are different, and if so, to step S61.

단계 S60에서, 두 인증값이 다른 경우는 서버 비밀키와 클라이언트 비밀키가 다른 경우로, 서버(2)는 클라이언트(1)의 송신자 인증이 실패한 것으로 간주하고 서버측 세션유지정보(난수 R, 공유키 K, 키 변형인수 K2 등)을 삭제하고 세션을 삭제한다. 이와 관련된 의사 코드는 하기와 같다. In step S60, if the two authentication values are different, the server secret key and the client secret key are different, the server 2 considers the sender authentication of the client 1 to have failed and server-side session maintenance information (random number R, shared). Key K, key modification factor K2, etc.) and delete the session. The pseudo code related to this is as follows.

Session destroy()Session destroy ()

그리고 클라이언트(1)에 저장된 클라이언트측 세션유지정보(공유키 K, 키 변형 인수 K2, 난수 R, 쿠키 등)가 모두 NULL로 설정되도록 하는 클라이언트측 스크립트, 플래시 또는 액티브X를 클라이언트(1)에 전송한다. 이 과정에서 사용자는 로그아웃된다. Then, the client-side script, flash, or ActiveX is transmitted to the client 1 so that all client-side session maintenance information (shared key K, key modification factor K2, random number R, cookie, etc.) stored in the client 1 is set to NULL. do. In this process, the user is logged out.

단계 S61에서, 두 인증값이 동일한 경우는 서버 비밀키와 클라이언트 비밀키가 동일한 경우로, 서버(2)는 클라이언트(1)의 송신자 인증이 성공한 것으로 간주 하고, 새로운 난수 R을 생성한다(단계 S62). 그리고 클라이언트(1)가 HTTP 요청을 통해 요청한 서비스에 대한 HTTP 응답에 새로 생성된 난수 R과 키 변형 인수 K2를 첨부하여 클라이언트(1)에 전송한다(단계 S63). 이후 서버(2)는 다른 HTTP 요청을 받게 되면 단계 S59 이하의 과정을 반복하게 된다. In step S61, if the two authentication values are the same, the server secret key and the client secret key are the same, the server 2 considers the sender authentication of the client 1 to be successful, and generates a new random number R (step S62). ). Then, the client 1 attaches the newly generated random number R and the key modification factor K2 to the HTTP response to the service requested by the HTTP request to the client 1 (step S63). Thereafter, when the server 2 receives another HTTP request, the server 2 repeats the process of step S59 or below.

상술한 사용자 세션 관리 방법을 이용하면 사용자의 세션 자체는 보호받을 수 있지만, 여전히 송수신되는 HTTP의 내용은 도청될 수 있다. 도청으로부터 송수신되는 내용을 보호하기 위해서 HTTP의 내용 중 중요한 내용(예를 들어, 인터넷 뱅킹 서비스에서 계좌번호 등)을 클라이언트(1)와 서버(2)가 공유하는 비밀키를 이용하여 암호화하여 전송한다. 여기서, 암호화는 AES(advanced encryption standard)의 암호루틴을 이용한다. Using the above-described user session management method, the user's session itself can be protected, but the contents of HTTP which are still transmitted and received can be intercepted. In order to protect the contents transmitted and received from eavesdropping, important contents of HTTP contents (for example, account number in Internet banking service) are encrypted and transmitted using a secret key shared by the client 1 and the server 2. . Here, the encryption uses an encryption routine of the advanced encryption standard (AES).

서버(2)가 HTTP 응답을 하는 경우 중요한 내용을 비밀키를 이용하여 암호화하고, 클라이언트(1)에서 이를 복호화할 수 있도록 하는 클라이언트측 스크립트, 플래시 또는 액티브X를 함께 클라이언트(1)로 전송한다. When the server 2 makes an HTTP response, it encrypts the important content using the secret key, and transmits a client-side script, flash, or ActiveX together with the client 1 to enable the client 1 to decrypt it.

클라이언트(1)가 HTTP 요청을 하는 경우 중요한 내용을 비밀키로 암호화할 수 있도록 하는 암호루틴을 서버(2)가 HTTP 응답에 포함하여 전송한다. 이 경우 클라이언트(1)는 HTTP 요청을 생성할 때 암호루틴에 따라 비밀키를 이용하여 HTTP 내용 중 중요한 내용은 암호화가 가능하다. When the client 1 makes an HTTP request, the server 2 transmits the encryption routine included in the HTTP response so that the important content can be encrypted with the secret key. In this case, when the client 1 generates an HTTP request, important contents of the HTTP contents can be encrypted using a secret key according to an encryption routine.

클라이언트(1)와 서버(2)는 비밀키 또는 비밀키를 생성할 수 있는 공유키를 공유하고 있으므로, 암호화된 내용을 복호화하는 것은 어렵지 않음을 당업자는 이 해할 것이다. Since the client 1 and the server 2 share a secret key or a shared key for generating a secret key, those skilled in the art will understand that it is not difficult to decrypt the encrypted contents.

이러한 HTTP 내용 중 일부의 암호화는 종래 SSL(secure sockets layer)을 이용한 것과는 다음과 같은 차이가 있다. SSL을 이용하는 경우 SSL은 전송 계층(Transport layer)이며, HTTP 내용 전체를 암호화하고, 도메인간의 세션 관리가 불가능하였다. 하지만, 상술한 것과 같이 클라이언트(1)와 서버(2)가 공유하고 있는 비밀키를 이용한 암호화는 응용 계층(Application layer)에서 이루어지며, HTTP 내용 중 일부만의 선택적인 암호화가 가능하고 도메인간의 세션 관리가 가능한 장점이 있다. The encryption of some of these HTTP contents is different from that of the conventional secure sockets layer (SSL) as follows. In case of using SSL, SSL is a transport layer, and the entire HTTP content is encrypted and session management between domains is not possible. However, as described above, the encryption using the secret key shared by the client 1 and the server 2 is performed in the application layer, and it is possible to selectively encrypt only some of the HTTP contents and manage sessions between domains. There is a possible advantage.

또한, 본 발명에서 윈도우 이름을 공유키의 저장 공간으로 이용하는 경우 자식 창을 사용하는 경우에는 window.name=opener.name과 같은 방법 등을 통해서 부모 창이 저장하고 있는 공유키를 자식 창에서도 공유하도록 한다. 여기서, opener.name이 부모 창의 윈도우 이름이다. In the present invention, when using a window name as a storage space for the shared key, when using a child window, the shared key stored in the parent window is shared in the child window through a method such as window.name = opener.name. . Where opener.name is the window name of the parent window.

한편, 상술한 사용자 세션 관리 방법은 컴퓨터 프로그램으로 작성 가능하다. 상기 프로그램을 구성하는 코드들 및 코드 세그먼트들은 당해 분야의 컴퓨터 프로그래머에 의하여 용이하게 추론될 수 있다. 또한, 상기 프로그램은 컴퓨터가 읽을 수 있는 정보저장매체(computer readable media)에 저장되고, 컴퓨터에 의하여 읽혀지고 실행됨으로써 문서 탐색 서비스 제공 방법을 구현한다. 상기 정보저장매체는 자기 기록매체, 광 기록매체, 및 캐리어 웨이브 매체를 포함한다.On the other hand, the user session management method described above can be created by a computer program. Codes and code segments constituting the program can be easily inferred by a computer programmer in the art. In addition, the program is stored in a computer readable media, and read and executed by a computer to implement a method for providing a document search service. The information storage medium includes a magnetic recording medium, an optical recording medium, and a carrier wave medium.

상기에서는 본 발명에 대하여 그 실시예를 중심으로 설명하였지만, 해당 기술 분야에서 통상의 지식을 가진 자라면 하기의 특허 청구의 범위에 기재된 본 발명의 사상 및 영역으로부터 벗어나지 않는 범위 내에서 본 발명을 다양하게 수정 및 변경시킬 수 있음을 이해할 수 있을 것이다.In the above, the present invention has been described based on the embodiments, but those skilled in the art may vary the present invention without departing from the spirit and scope of the present invention as set forth in the claims below. It will be understood that modifications and changes can be made.

도 1은 본 발명에 적용되는 시도-응답 프로토콜의 인증 방법을 설명한 도면. 1 illustrates an authentication method of a challenge-response protocol applied to the present invention.

도 2는 본 발명의 일 실시예에 따른 서버에 포함되는 세션 관리 모듈의 블록구성도.2 is a block diagram of a session management module included in a server according to an embodiment of the present invention.

도 3은 본 발명의 일 실시예에 따른 안전한 사용자 세션 관리 방법, HTTP 요청의 송신자 인증 프로토콜을 설명한 도면. 3 is a diagram illustrating a secure user session management method and a sender authentication protocol of an HTTP request according to an embodiment of the present invention.

도 4는 본 발명의 다른 실시예에 따른 안전한 사용자 세션 관리 방법, 키 보호모드에서의 HTTP 요청의 송신자 인증 프로토콜을 설명한 도면. 4 is a diagram illustrating a secure user session management method and a sender authentication protocol of an HTTP request in key protected mode according to another embodiment of the present invention.

<도면의 주요부분에 대한 부호의 설명><Description of the symbols for the main parts of the drawings>

1: 클라이언트1: client

2: 서버2: server

Claims (27)

웹 환경에서 네트워크를 통해 클라이언트와 연결된 서버에서 상기 클라이언트와의 사용자 세션을 관리하는 방법에 있어서,In the web environment, a method for managing a user session with the client in a server connected to the client over a network, 상기 서버가 상기 클라이언트로부터 쿠키(cookie)를 포함하는 제1 HTTP 요청(HTTP request)을 전송받는 단계-여기서, 상기 쿠키는 클라이언트 인증값을 포함하고, 상기 클라이언트 인증값은 상기 클라이언트에 저장된 공유키와 상기 클라이언트가 직전에 전송받은 제1 HTTP 응답(HTTP response)에 포함된 세션정보를 이용하여 계산됨-;The server receiving a first HTTP request including a cookie from the client, wherein the cookie includes a client authentication value, the client authentication value being a shared key stored in the client; Calculated by using the session information included in the first HTTP response received by the client immediately before; 상기 쿠키에 포함된 클라이언트 인증값과 서버 인증값을 비교하는 단계-상기 서버 인증값은 상기 세션정보와 상기 서버에 저장된 공유키를 이용하여 계산됨-; 및Comparing a client authentication value and a server authentication value included in the cookie, wherein the server authentication value is calculated using the session information and a shared key stored in the server; And 상기 비교 결과에 따라 상기 클라이언트의 송신자 인증 성공 또는 실패를 결정하는 단계를 포함하는 사용자 세션 관리 방법. And determining success or failure of sender authentication of the client according to the comparison result. 제1항에 있어서,The method of claim 1, 상기 서버는 상기 클라이언트로부터의 사용자 로그인 과정에서 상기 공유키를 상기 클라이언트와 공유하는 것을 특징으로 하는 사용자 세션 관리 방법. And the server shares the shared key with the client during a user login process from the client. 제1항에 있어서,The method of claim 1, 상기 제1 HTTP 요청은 송신자 인증을 필요로 하는 것을 특징으로 하는 사용자 세션 관리 방법.And the first HTTP request requires sender authentication. 제1항에 있어서,The method of claim 1, 상기 송신자 인증 성공 또는 실패 결정 단계는, The sender authentication success or failure determination step, 상기 서버 인증값과 상기 클라이언트 인증값이 동일한 경우 상기 사용자 세션이 유효한 것으로 간주하여 상기 세션정보를 갱신하고, 상기 갱신된 세션정보에 상응하는 서버 인증값을 계산하며, 상기 제1 HTTP 요청에 대한 제2 HTTP 응답에 상기 갱신된 세션정보를 포함시켜 상기 클라이언트에 전송하는 것을 특징으로 하는 사용자 세션 관리 방법. If the server authentication value and the client authentication value are the same, the user session is regarded as valid and the session information is updated, a server authentication value corresponding to the updated session information is calculated, and 2. The method of claim 1, wherein the updated session information is included in an HTTP response and transmitted to the client. 제4항에 있어서,The method of claim 4, wherein 상기 사용자 세션이 유효한 것으로 간주하는 경우 If the user session is considered valid 상기 제2 HTTP 응답은 상기 클라이언트가 저장하고 있는 공유키와 상기 제2 HTTP 응답에 포함된 상기 세션정보를 이용하여 일방향 함수로 상기 클라이언트 인증값을 계산하고, 상기 클라이언트 인증값을 상기 쿠키에 포함시키도록 하는 실행 코드를 포함하는 것을 특징으로 하는 사용자 세션 관리 방법.The second HTTP response calculates the client authentication value using a one-way function by using the shared key stored by the client and the session information included in the second HTTP response, and includes the client authentication value in the cookie. User session management method comprising the execution code to make. 제5항에 있어서,The method of claim 5, 상기 서버 인증값은 상기 클라이언트 인증값을 계산한 일방향 함수와 동일한 함수로 계산한 것을 특징으로 하는 사용자 세션 관리 방법. And the server authentication value is calculated using the same function as the one-way function that calculates the client authentication value. 제1항에 있어서,The method of claim 1, 상기 인증 성공 또는 실패 결정 단계는, The authentication success or failure determination step, 상기 서버 인증값과 상기 클라이언트 인증값이 다른 경우 상기 사용자 세션이 유효하지 않은 것으로 간주하여 상기 서버는 상기 사용자 세션을 삭제하는 것을 특징으로 하는 사용자 세션 관리 방법.And if the server authentication value and the client authentication value are different, the server considers the user session invalid and deletes the user session. 제7항에 있어서,The method of claim 7, wherein 상기 사용자 세션이 유효하지 않은 것으로 간주하는 경우 If the user session is considered invalid 상기 서버는 상기 클라이언트의 상기 공유키, 상기 세션정보, 상기 클라이언트 인증값 및 상기 쿠키 중 적어도 하나를 NULL로 만드는 클라이언트측 스크립트(Client Side Script), 플래시(Flash) 또는 액티브X(ActiveX)를 상기 클라이언트 에 전송하는 것을 특징으로 하는 사용자 세션 관리 방법.The server may generate a client side script, flash, or ActiveX to make at least one of the shared key, the session information, the client authentication value, and the cookie of the client NULL. And transmitting to the user session management method. 제1항에 있어서,The method of claim 1, 상기 서버는 상기 클라이언트와 상기 공유키를 공유하는 단계; The server sharing the shared key with the client; 상기 클라이언트로부터 제2 HTTP 요청을 전송받는 단계;Receiving a second HTTP request from the client; 상기 세션정보를 생성하는 단계; 및Generating the session information; And 상기 세션정보를 상기 제2 HTTP 요청에 대한 상기 제1 HTTP 응답에 포함시켜 상기 클라이언트에 전송하는 단계가 선행하는 것을 특징으로 하는 사용자 세션 관리 방법. And transmitting the session information to the client by including the session information in the first HTTP response to the second HTTP request. 제1항에 있어서,The method of claim 1, 상기 서버는 웹 어플리케이션에서 제공하는 세션 또는 데이터베이스에 상기 공유키, 상기 세션정보와 상기 서버 인증값을 저장하는 것을 특징으로 하는 사용자 세션 관리 방법. And the server stores the shared key, the session information, and the server authentication value in a session or a database provided by a web application. 제1항에 있어서,The method of claim 1, 상기 서버는 상기 제1 HTTP 응답시 HTTP 내용 중 일부를 상기 공유키를 이용 하여 암호화하고, 이를 복호화할 수 있는 클라이언트측 스크립트, 플래시 또는 액티브X를 포함하여 상기 클라이언트에 전송하는 단계를 더 포함하는 것을 특징으로 하는 사용자 세션 관리 방법.The server further includes the step of encrypting a portion of the HTTP content in the first HTTP response using the shared key, and transmitting to the client, including a client-side script, Flash or ActiveX that can decrypt it Characterized by the user session management method. 제1항에 있어서,The method of claim 1, 상기 서버는 상기 제1 HTTP 응답시 상기 클라이언트가 HTTP 내용 중 일부를 암호화할 수 있도록 하는 암호 루틴을 포함하여 상기 클라이언트에 전송하는 단계를 더 포함하되, The server further includes the step of transmitting to the client, including a cryptographic routine that allows the client to encrypt some of the HTTP content in the first HTTP response, 상기 클라이언트는 상기 암호 루틴에 따라 상기 공유키를 이용하여 상기 HTTP 내용 중 일부가 암호화된 상기 제1 HTTP 요청을 상기 서버에 전송하는 것을 특징으로 하는 사용자 세션 관리 방법. And the client transmits the first HTTP request in which a part of the HTTP content is encrypted using the shared key to the server according to the encryption routine. 제1항에 있어서,The method of claim 1, 상기 세션정보는 난수(random number)인 것을 특징으로 하는 사용자 세션 관리 방법. And the session information is a random number. 제1항에 있어서,The method of claim 1, 상기 세션정보는 난수와 키 변형 인수를 포함하는 것을 특징으로 하는 사용자 세션 관리 방법. And the session information includes a random number and a key transformation factor. 제14항에 있어서,The method of claim 14, 상기 서버 인증값은 상기 서버에 저장된 상기 공유키 및 상기 키 변형 인수를 이용하여 계산한 서버 비밀키와, 상기 난수를 인수로 하는 일방향 함수로 계산되는 것을 특징으로 하는 사용자 세션 관리 방법. And the server authentication value is calculated using a server secret key calculated using the shared key and the key modification factor stored in the server, and a one-way function taking the random number as an argument. 제15항에 있어서,The method of claim 15, 상기 클라이언트 인증값은 상기 클라이언트에 저장된 상기 공유키 및 상기 클라이언트가 상기 서버로부터 전송받은 상기 제1 HTTP 응답에 포함된 상기 키 변형 인수를 이용하여 계산한 클라이언트 비밀키와, 상기 제1 HTTP 응답에 포함된 상기 난수를 인수로 하는 일방향 함수로 계산되는 것을 특징으로 하는 사용자 세션 관리 방법. The client authentication value is included in the first HTTP response and the client secret key calculated using the shared key stored in the client and the key modification factor included in the first HTTP response received by the client from the server. And calculating a one-way function using the random number as an argument. 웹 환경에서 네트워크를 통해 서버와 연결된 클라이언트에서 사용자 세션을 관리하는 방법에 있어서,In a web environment, a method for managing a user session from a client connected to a server via a network, 상기 클라이언트가 상기 서버와 공유키를 공유하는 단계;Sharing, by the client, a shared key with the server; 상기 공유키를 웹 브라우저의 문서 객체 모델(DOM: Document Object Model)의 윈도우 객체의 속성 중 윈도우 이름(window.name), 플래시(Flash)의 지역 공유 객체(LSO: Local Shared Object) 또는 액티브X에 저장하는 단계;The shared key may be assigned to a window name (window.name), a local shared object (LSO) or ActiveX of a window object of a document object model (DOM) of a web browser. Storing; 상기 서버로부터의 HTTP 응답을 전송받는 단계-상기 HTTP 응답은 상기 서버에서 생성된 세션정보를 포함함-;Receiving an HTTP response from the server, wherein the HTTP response includes session information generated at the server; 상기 세션정보와 상기 공유키를 이용하여 클라이언트 인증값을 계산하는 단계; 및Calculating a client authentication value using the session information and the shared key; And 상기 클라이언트 인증값을 쿠키에 저장하는 단계를 포함하는 사용자 세션 관리 방법. And storing the client authentication value in a cookie. 제17항에 있어서,The method of claim 17, 송신자 인증이 필요한 HTTP 요청시 상기 쿠키를 포함하여 상기 서버에 전송하는 단계를 더 포함하는 것을 특징으로 하는 사용자 세션 관리 방법. And transmitting the cookie to the server in response to an HTTP request requiring sender authentication. 제17항에 있어서,The method of claim 17, 상기 클라이언트 인증값은 상기 세션정보와 상기 공유키를 이용하여 일방향 함수로 계산된 것을 특징으로 하는 사용자 세션 관리 방법. The client authentication value is calculated using a one-way function using the session information and the shared key. 제17항에 있어서,The method of claim 17, 상기 HTTP 응답은 상기 클라이언트가 HTTP 내용 중 일부를 암호화할 수 있도록 하는 암호 루틴을 포함하여 상기 클라이언트에 전송되되,The HTTP response is sent to the client including a cryptographic routine that allows the client to encrypt some of the HTTP content. 상기 클라이언트는 상기 암호 루틴에 따라 상기 공유키를 이용하여 상기 HTTP 내용 중 일부가 암호화된 HTTP 요청을 상기 서버에 전송하는 단계를 더 포함하는 것을 특징으로 하는 사용자 세션 관리 방법. And transmitting, by the client, the HTTP request encrypted with a portion of the HTTP content to the server by using the shared key according to the encryption routine. 제17항에 있어서,The method of claim 17, 상기 세션정보는 난수인 것을 특징으로 하는 사용자 세션 관리 방법. And the session information is a random number. 제17항에 있어서,The method of claim 17, 상기 세션정보는 난수와 키 변형 인수를 포함하는 것을 특징으로 하는 사용자 세션 관리 방법. And the session information includes a random number and a key transformation factor. 제22항에 있어서,The method of claim 22, 상기 클라이언트 인증값은 상기 클라이언트에 저장된 상기 공유키 및 상기 키 변형 인수를 이용하여 계산한 클라이언트 비밀키와, 상기 HTTP 응답에 포함된 상기 난수를 인수로 하는 일방향 함수로 계산되는 것을 특징으로 하는 사용자 세션 관리 방법. The client authentication value is calculated as a one-way function that takes a client secret key calculated using the shared key and the key modification factor stored in the client, and the random number included in the HTTP response. How to manage. 제1항 내지 제16항 중 어느 한 항의 방법을 컴퓨터에서 실행하기 위한 프로그램을 기록하는 컴퓨터 판독 가능한 기록매체.A computer-readable recording medium for recording a program for executing the method of any one of claims 1 to 16 on a computer. 제17항 내지 제23항 중 어느 한 항의 방법을 컴퓨터에서 실행하기 위한 프로그램을 기록하는 컴퓨터 판독 가능한 기록매체.A computer-readable recording medium for recording a program for executing the method of any one of claims 17 to 23 on a computer. 웹 환경에서 네트워크를 통해 연결된 클라이언트와 서버 간의 사용자 세션을 관리하는 시스템에 있어서, In a system for managing user sessions between a client and a server connected through a network in a web environment, 상기 클라이언트와 상기 서버는 공유키를 공유하고, The client and the server share a shared key, 상기 사용자 세션이 유효한 동안 상기 클라이언트로부터의 HTTP 요청(HTTP request)이 시도-응답 프로토콜(challenge-response protocol) 중 응답(response) 과정에 해당하고, 상기 서버로부터의 HTTP 응답(HTTP response)이 상기 시도-응답 프로토콜 중 시도(challenge) 과정에 해당하는 것을 특징으로 하는 사용자 세션 관리 시스템.While the user session is valid, an HTTP request from the client corresponds to a response process of a challenge-response protocol, and an HTTP response from the server User session management system, characterized in that corresponding to the challenge (challenge) process of the response protocol. 제26항에 있어서, The method of claim 26, 상기 서버는 상기 공유키를 이용하여 생성한 서버측 세션유지정보와, 상기 공유키를 이용하여 상기 클라이언트에서 생성한 상기 클라이언트측 세션유지정보-여기서, 상기 클라이언트측 세션유지정보는 상기 HTTP 요청에 포함됨-를 비교하여 상기 사용자 세션의 유효 여부를 결정하는 사용자 세션 관리 시스템. The server generates server-side session maintenance information generated by using the shared key and the client-side session maintenance information generated by the client by using the shared key, wherein the client-side session maintenance information is included in the HTTP request. And compare the-to determine whether the user session is valid.
KR1020070100638A 2007-10-05 2007-10-05 Secure user session managing method and system under web environment, recording medium recorded program executing it KR100915003B1 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
KR1020070100638A KR100915003B1 (en) 2007-10-05 2007-10-05 Secure user session managing method and system under web environment, recording medium recorded program executing it
US11/965,941 US20090094372A1 (en) 2007-10-05 2007-12-28 Secret user session managing method and system under web environment, recording medium recorded program executing it

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020070100638A KR100915003B1 (en) 2007-10-05 2007-10-05 Secure user session managing method and system under web environment, recording medium recorded program executing it

Publications (2)

Publication Number Publication Date
KR20090035382A true KR20090035382A (en) 2009-04-09
KR100915003B1 KR100915003B1 (en) 2009-09-02

Family

ID=40760833

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020070100638A KR100915003B1 (en) 2007-10-05 2007-10-05 Secure user session managing method and system under web environment, recording medium recorded program executing it

Country Status (1)

Country Link
KR (1) KR100915003B1 (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2014035220A2 (en) * 2012-09-03 2014-03-06 엘지이노텍 주식회사 Method and system for program authentication
CN113573307A (en) * 2021-07-28 2021-10-29 西安热工研究院有限公司 Rapid authentication method based on extensible authentication protocol
WO2023286985A1 (en) * 2021-07-16 2023-01-19 (주)모니터랩 Security device user authentication method using cookies

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20030054859A (en) * 2001-12-26 2003-07-02 엘지전자 주식회사 User Connection Confirm Method of Web Server
KR100490584B1 (en) * 2003-03-19 2005-05-17 학교법인 이화학당 secure cookie processing method for single sign-on on web

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2014035220A2 (en) * 2012-09-03 2014-03-06 엘지이노텍 주식회사 Method and system for program authentication
KR20140044955A (en) * 2012-09-03 2014-04-16 엘지이노텍 주식회사 Method for certificating program
WO2014035220A3 (en) * 2012-09-03 2014-04-24 엘지이노텍 주식회사 Method and system for program authentication
US9355243B2 (en) 2012-09-03 2016-05-31 Lg Innotek Co., Ltd. Method and system for program authentication
WO2023286985A1 (en) * 2021-07-16 2023-01-19 (주)모니터랩 Security device user authentication method using cookies
CN113573307A (en) * 2021-07-28 2021-10-29 西安热工研究院有限公司 Rapid authentication method based on extensible authentication protocol
CN113573307B (en) * 2021-07-28 2024-01-30 西安热工研究院有限公司 Rapid authentication method based on extensible authentication protocol

Also Published As

Publication number Publication date
KR100915003B1 (en) 2009-09-02

Similar Documents

Publication Publication Date Title
US20090094372A1 (en) Secret user session managing method and system under web environment, recording medium recorded program executing it
JP4864289B2 (en) Network user authentication system and method
US8185942B2 (en) Client-server opaque token passing apparatus and method
US9191375B2 (en) System and method for accessing integrated applications in a single sign-on enabled enterprise solution
US7861087B2 (en) Systems and methods for state signing of internet resources
US6912653B2 (en) Authenticating communications
US7150038B1 (en) Facilitating single sign-on by using authenticated code to access a password store
US9172707B2 (en) Reducing cross-site scripting attacks by segregating HTTP resources by subdomain
EP4191955A1 (en) Method and device for securely accessing intranet application
JP4256361B2 (en) Authentication management method and system
WO2000079432A1 (en) Enhanced security for applications employing downloadable executable content
WO2010003261A1 (en) Web application security filtering
CN107872455A (en) A kind of cross-domain single login system and its method
CN106685973A (en) Method and device for remembering log in information, log in control method and device
US20100275025A1 (en) Method and apparatus for secure communication
Ulybyshev et al. Privacy-preserving data dissemination in untrusted cloud
KR100915003B1 (en) Secure user session managing method and system under web environment, recording medium recorded program executing it
KR100969196B1 (en) Secure user session managing method under web environment and recording medium recorded program executing it
Aljawarneh Emerging challenges, security issues, and Technologies in Online Banking Systems
KR100892609B1 (en) System and method for secure communication, and a medium having computer readable program executing the method
CN116034596A (en) Anonymous authentication with token redemption
Singh et al. Prevention of session hijacking using token and session id reset approach
Corella Overcoming the UX Challenges Faced by FIDO Credentials in the Consumer Space
KR101001765B1 (en) Method and System for Authenticating Client Using Sharing Seed
KR20130071674A (en) System and method for verifying integrity of web page

Legal Events

Date Code Title Description
A201 Request for examination
E902 Notification of reason for refusal
E701 Decision to grant or registration of patent right
GRNT Written decision to grant
FPAY Annual fee payment

Payment date: 20130527

Year of fee payment: 5

FPAY Annual fee payment

Payment date: 20140612

Year of fee payment: 6

FPAY Annual fee payment

Payment date: 20150626

Year of fee payment: 7

FPAY Annual fee payment

Payment date: 20160602

Year of fee payment: 8

LAPS Lapse due to unpaid annual fee