Can not create name pipe in *.api, have the access denied error

New Here ,
Nov 25, 2020 Nov 25, 2020

Copy link to clipboard

Copied

Dear All,

 

I just want to create a name pipe in *.api for adobe reader as follow, by using visual C++.

hPipe = CreateNmaedPipe(L"\\\\.\\pipe\\my_pipe", PIPE_ACCESS_DUPLEX, PIPE_TYPE_MESSAGE | PIPE_READMODE_MESSAGE | PIPE_NOWAIT, PIPE_UNLIMITED_INSTANCES, 4096, 4096, 1000, NULL);

and put *.api in the adobe plugin,  open adobe and call this.

But hPipe will return INVALID_HANDLE_VALUE and GetLastError as 5, Access Denied.

 

If I only run the is code in invidual c++ project and run it directly, it can be successful. Anyone has this idea?

 

Thanks,

Tony

 

 

TOPICS
General troubleshooting

Views

94

Likes

translate

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Most Valuable Participant ,
Nov 26, 2020 Nov 26, 2020

Copy link to clipboard

Copied

Look under Reader Preferences, Security (enhanced). Are you running with "Enable Protected Mode At Startup" switch ON?

Likes

translate

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Nov 26, 2020 Nov 26, 2020

Copy link to clipboard

Copied

I only downloaded Adobe Reader DC SDK, how can I enable "Enable Protected Mode at Startup"? It is inside in SDK?

Likes

translate

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Most Valuable Participant ,
Nov 26, 2020 Nov 26, 2020

Copy link to clipboard

Copied

If you only just downloaded the SDK, do you already have a Reader-enabling license and key from Adobe? Not sure how you can just download the SDK and make a Reader plug-in without all this extra work?  

Likes

translate

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Dec 14, 2020 Dec 14, 2020

Copy link to clipboard

Copied

Enable protected mode, it is fine now.

 

Likes

translate

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Dec 17, 2020 Dec 17, 2020

Copy link to clipboard

Copied

I want to know whether it must be protected mode, if I need to use sandbox and broker.exe.

Likes

translate

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Most Valuable Participant ,
Dec 18, 2020 Dec 18, 2020

Copy link to clipboard

Copied

Yes, Acrobat and Reader plug-ins only offer the Broker feature when protected mode is on. This means that you need to code some parts of your code twice, completely differently. 

Likes

translate

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Dec 18, 2020 Dec 18, 2020

Copy link to clipboard

Copied

Actually I want to communicate between plugin with C# tray programe. The purpose is to open/save file from C#. plugin need to send command to C# to open file and receive file path and name from C#, then use adobe api open it. When save, will use adobe api save file then send file path and name to C#. Which communication method doesn't need sandbox and protected mode?

Likes

translate

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Most Valuable Participant ,
Dec 18, 2020 Dec 18, 2020

Copy link to clipboard

Copied

If you want your plug-in to run in Protected mode it probably needs to use a broker. If your plug-in needs to run with Protected mode OFF, it must use a different method. If your end users can choose whether this option is on or off, you must support both.g

Likes

translate

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines