Click here to Skip to main content
16,016,334 members
Home / Discussions / COM
   

COM

 
GeneralDCOM security on XP Pin
Tim Smith9-Oct-01 13:02
Tim Smith9-Oct-01 13:02 
QuestionHow to add new icons to the existing ms-word application Pin
RamiReddy8-Oct-01 20:25
RamiReddy8-Oct-01 20:25 
AnswerRe: How to add new icons to the existing ms-word application Pin
Shadi Al-Kahwaji11-Oct-01 3:18
Shadi Al-Kahwaji11-Oct-01 3:18 
GeneralDCOM and ConnectionPoint Pin
Firoz8-Oct-01 2:31
Firoz8-Oct-01 2:31 
GeneralRe: DCOM and ConnectionPoint Pin
Rashid Thadha9-Oct-01 2:35
Rashid Thadha9-Oct-01 2:35 
GeneralRe: DCOM and ConnectionPoint Pin
Tim Smith9-Oct-01 13:03
Tim Smith9-Oct-01 13:03 
GeneralRe: Ok, here is the info... Pin
Tim Smith10-Oct-01 3:14
Tim Smith10-Oct-01 3:14 
GeneralRe: Ok, here is the info... Pin
Rashid Thadha10-Oct-01 10:30
Rashid Thadha10-Oct-01 10:30 
Excellent solution (about removing the security from the client), very clever, fits in with what Jeff Prosise says about connection points.

extract from Jeff Prosise article
One of the errors that newbies often experience when they first
begin tinkering with DCOM occurs when they fail to give a remote 
server process permission to perform callbacks to a client. 
Suppose a client on machine A launches a COM server on machine B 
and receives an interface pointer in return. Then that client 
passes an interface pointer of its own to the server so the 
server can perform callbacks. 

What's wrong with this picture? Nothing, except for the fact 
that callbacks will only be permitted if the server process is 
granted access permission to the client process. If the server 
process is assigned the identity Mister Server, then Mister 
Server must be granted access permission to the client process. 
One way to grant that access permission is to have the client 
process call CoInitializeSecurity. Another way is to include 
Mister Server (or Everyone) in the client machine's 
DefaultAccessPermission ACL. 


What makes this error especially difficult to diagnose is that 
if connection points are involved, the failure typically doesn't 
occur when the server attempts its first callback; it occurs 
when the client passes its interface pointer to the server using 
IConnectionPoint::Advise. Most implementations of Advise, 
including ATL's, call QueryInterface on the client. But if the 
server process lacks access permissions in the client process, 
QueryInterface will fail. When Advise sees QueryInterface fail,
Advise will fail, too. 

The moral: If you're using connection points to facilitate 
callbacks from remote servers and IConnectionPoint::Advise 
returns E_ACCESSDENIED or E_OUTOFMEMORY, check the access 
permissions on the client. Chances are the security principal
whose identity the server process has been assigned does not 
have permission to call into the client process. 

Read the full security article at

http://www.codeguru.com/activex/COMSecurity1.html

and

http://www.codeguru.com/activex/COMSecurity2.html
GeneralRe: Ok, here is the info... Pin
Tim Smith10-Oct-01 12:36
Tim Smith10-Oct-01 12:36 
GeneralThats Great , but a small problem... Pin
Firoz10-Oct-01 19:59
Firoz10-Oct-01 19:59 
GeneralRe: DCOM and ConnectionPoint Pin
Shadi Al-Kahwaji11-Oct-01 1:13
Shadi Al-Kahwaji11-Oct-01 1:13 
GeneralRe: DCOM and ConnectionPoint Pin
Firoz11-Oct-01 2:35
Firoz11-Oct-01 2:35 
GeneralCalling a COM object in an MFC exe Pin
Aza7-Oct-01 5:37
Aza7-Oct-01 5:37 
GeneralRe: Calling a COM object in an MFC exe Pin
Rashid Thadha9-Oct-01 2:40
Rashid Thadha9-Oct-01 2:40 
Generalusing list view in ATL property page Pin
Sameer Bhat7-Oct-01 4:11
Sameer Bhat7-Oct-01 4:11 
GeneralRe: using list view in ATL property page Pin
Amit Dey13-Oct-01 6:27
Amit Dey13-Oct-01 6:27 
GeneralRe: using list view in ATL property page Pin
Sameer Bhat14-Oct-01 2:20
Sameer Bhat14-Oct-01 2:20 
GeneralOLE Control in Visual Basic Pin
7-Oct-01 0:22
suss7-Oct-01 0:22 
QuestionAbout Com:I need help with the following code(simplified)? Pin
star_see5-Oct-01 19:52
star_see5-Oct-01 19:52 
AnswerRe: About Com:I need help with the following code(simplified)? Pin
Shadi Al-Kahwaji6-Oct-01 23:21
Shadi Al-Kahwaji6-Oct-01 23:21 
GeneralRe: About Com:I need help with the following code(simplified)? Pin
star_see20-Oct-01 5:34
star_see20-Oct-01 5:34 
GeneralBeginning - direction Pin
john john mackey5-Oct-01 7:37
john john mackey5-Oct-01 7:37 
GeneralCreating a new thread from within an MTA Pin
Jeremy Pullicino4-Oct-01 5:15
Jeremy Pullicino4-Oct-01 5:15 
GeneralRe: Creating a new thread from within an MTA Pin
Shadi Al-Kahwaji6-Oct-01 23:33
Shadi Al-Kahwaji6-Oct-01 23:33 
GeneralRe: Creating a new thread from within an MTA Pin
Jeremy Pullicino8-Oct-01 21:07
Jeremy Pullicino8-Oct-01 21:07 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.