성태의 닷넷 이야기
홈 주인
모아 놓은 자료
프로그래밍
질문/답변
사용자 관리
사용자
메뉴
아티클
외부 아티클
유용한 코드
온라인 기능
MathJax 입력기
최근 덧글
[정성태] 제가 큰 실수를 했군요. ^^; Delegate를 통한 Bein...
[정성태] Working with Rust Libraries from C#...
[정성태] Detecting blocking calls using asyn...
[정성태] 아쉽게도, 커뮤니티는 아니고 개인 블로그입니다. ^^
[정성태] 질문이 잘 이해가 안 됩니다. 우선, 해당 소스코드에서 ILis...
[양승조
] var대신 dinamic으로 선언해서 해결은 했습니다. 맞는 해...
[양승조
] 또 막혔습니다. ㅠㅠ var list = props[i].Ge...
[양승조
] 아. 감사합니다. 어제는 안됐던것 같은데....정신을 차려야겠네...
[정성태] "props[i].GetValue(props[i])" 코드에서 ...
[정성태] 저렇게 조각 코드 말고, 실제로 재현이 되는 예제 프로젝트를 압...
글쓰기
제목
이름
암호
전자우편
HTML
홈페이지
유형
제니퍼 .NET
닷넷
COM 개체 관련
스크립트
VC++
VS.NET IDE
Windows
Team Foundation Server
디버깅 기술
오류 유형
개발 환경 구성
웹
기타
Linux
Java
DDK
Math
Phone
Graphics
사물인터넷
부모글 보이기/감추기
내용
오랜만에 asp 페이지 테스트를 해봤습니다.<br /> <br /> 간단한 ATL 개체를 하나 만들고, 컴파일한 후 asp 페이지에서 다음과 같이 생성했습니다.<br /> <br /> <pre class="code"> <%@ Language=VBScript %> <% Dim testObj Set testObj = Server.CreateObject( "TestATL.SimpleObj" ) %> </pre> <br /> 그런데, 다음과 같이 아무런 단서도 없는 오류 화면만 나오는 것입니다.<br /> 테스트 환경: Windows 2003 SP1, VS.NET 2005<br /> <br /> <pre class="code"> <table width="400" cellpadding="3" cellspacing="5"> <tr> <td id="tableProps" valign="top" align="left"><img id="pagerrorImg" SRC="pagerror.gif" width="25" height="33"></td> <td id="tableProps2" align="left" valign="middle" width="360"><h1 id="errortype" style="COLOR: black; FONT: 13pt/15pt verdana"><span id="errorText">The page cannot be displayed</span></h1> </td> </tr> <tr> <td id="tablePropsWidth" width="400" colspan="2"><font style="COLOR: black; FONT: 8pt/11pt verdana">There is a problem with the page you are trying to reach and it cannot be displayed.</font></td> </tr> <tr> <td id="tablePropsWidth" width="400" colspan="2"><font id="LID1" style="COLOR: black; FONT: 8pt/11pt verdana"><hr color="#C0C0C0" noshade> <p id="LID2">Please try the following:</p><ul> <li id="instructionsText1">Open the <span id="homepageContainer"></span> home page, and then look for links to the information you want. </li> <li id="instructionsText2">Click the <a xhref="javascript:location.reload()" target="_self"> <img border=0 src="refresh.gif" width="13" height="16" alt="refresh.gif (82 bytes)" align="middle"></a> <a xhref="javascript:location.reload()" target="_self">Refresh</a> button, or try again later.<br> </li> <li ID="instructionsText3">Click <a href="javascript:doSearch()"><img border=0 src="search.gif" width="16" height="16" alt="search.gif (114 bytes)" align="center"> Search</a> to look for information on the Internet. </li> <li id="instructionsText4">You can also see <a onclick="Related();event.returnValue=false" href="">a list of related sites.</a> </ul> </p> <p><br> </p> <h2 id="ietext" style="font:8pt/11pt verdana; color:black">HTTP 500 - Internal server error <br> Internet Explorer </h2> </font></td> </tr> </table> </pre> <br /> 이벤트 로그에도 아무런 오류도 안 남더군요. 이런 황당한 상황이. ^^; 도대체 어떤 정보를 가지고 오류 추적을 하라는 것인지.<br /> <br /> 그래도 평소 들었던 풍월이 있던지라, 오류 메시지를 개발자에게 도움이 되는 메시지로 보는 설정이 생각났습니다. 이 설정은 의외로, IIS 서버에서 이뤄지는 것이 아니고 클라이언트 측 IE에서 해주어야 하는 것이죠. 자세한 설명은 다음의 URL을 참고하십시오.<br /> <br /> <a target="_blank" href="http://support.microsoft.com/default.aspx?scid=kb%3Bko%3B311766">http://support.microsoft.com/default.aspx?scid=kb%3Bko%3B311766</a><br /> <br /> 일단, 위와 같이 적용하고 나니, 오류 메시지는 아래와 같이 변경이 되어서 출력이 되었습니다.<br /> <br /> <pre class="code"> error 'ASP 0178 : 80070005' Server.CreateObject Access Error /comp/test.asp, line 8 The call to Server.CreateObject failed while checking permissions. Access is denied to this object. </pre> <br /> 휴... 그나마 다행이군요. ^^<br /> 단서가 충분하게 나왔습니다. 권한이 없다고 하니, 탐색기에서 해당 DLL의 권한을 살펴보았습니다. 다음과 같이 설정되어져 있었습니다.<br /> <br /> <img alt="DLL 접근 권한" src="/SysWebRes/bbs/comobject_dll_properites_security_tab.png" /><br /> <br /> 제 시스템의 asp가 구동되는 w3wp.exe는 Application Pool의 설정에서 "SYSTEM" 권한으로 구동되도록 설정되어져 있었습니다. 아래의 화면에서는 그 SYSTEM 권한에 대해서 읽기 정도는 허용하도록 설정되어 있기 때문에 얼핏 문제가 없어 보입니다.<br /> <br /> 하지만, asp의 내부 동작을 살펴보면 분명 오류가 있다는 것을 알 수 있습니다.<br /> 해당 asp 페이지를 실행시키는 동안은 스레드의 실행 권한이 프로세스 실행 권한이 아닌, IIS 관리자의 보안 탭에서 설정한 "익명 액세스 접근 허용"에 따라 IUSR_[COMPUTERNAME]으로 설정되기 때문입니다.<br /> <br /> 그럼, 문제는 해결된 것 같습니다. 해당 DLL의 보안 탭에서 "IUSR_[COMPUTERNAME]" 또는 "Users"를 추가하고 Read 권한을 주면 되는 것입니다.
첨부파일
스팸 방지용 인증 번호
2200
(왼쪽의 숫자를 입력해야 합니다.)