Microsoftコードを使用して名前付きパイプを作成しようとしています:
http://code.msdn.microsoft.com/windowsdesktop/CppNamedPipeClient-a88eb958
また、別の場所からセキュリティ トークンを取得しました。
SECURITY_ATTRIBUTES sa;
sa.lpSecurityDescriptor = (PSECURITY_DESCRIPTOR)malloc(
SECURITY_DESCRIPTOR_MIN_LENGTH);
InitializeSecurityDescriptor(sa.lpSecurityDescriptor,
SECURITY_DESCRIPTOR_REVISION);
// ACL is set as NULL in order to allow all access to the object.
SetSecurityDescriptorDacl(sa.lpSecurityDescriptor, TRUE, NULL, FALSE);
sa.nLength = sizeof(sa);
sa.bInheritHandle = TRUE;
イントラネット上の他のPCからサーバーにアクセスできるように、IPでローカルではなくサーバーを宣言したい:
#define SERVER_NAME L"10.12.13.122" ("." works)
#define PIPE_NAME L"SamplePipe"
#define FULL_PIPE_NAME L"\\\\" SERVER_NAME L"\\pipe\\" PIPE_NAME
以前に C++ でこれを宣言した人はいますか? これは名前付きパイプの作成を拒否しています...