프로젝트

일반

사용자정보

통계
| 브랜치(Branch): | 개정판:

markus / IIpc / IpcBinding.cs @ 664ea2e1

이력 | 보기 | 이력해설 | 다운로드 (1.31 KB)

1 664ea2e1 taeseongkim
using System;
2
using System.Collections.Generic;
3
using System.Linq;
4
using System.ServiceModel;
5
using System.Text;
6
using System.Threading.Tasks;
7
8
namespace IIpc
9
{
10
    public static class IpcBinding
11
    {
12
        public static NetNamedPipeBinding netNamedPipeBinding()
13
        {
14
            NetNamedPipeBinding binding = new NetNamedPipeBinding
15
            {
16
                CloseTimeout = new TimeSpan(0, 1, 0),
17
                OpenTimeout = new TimeSpan(0, 1, 0),
18
                ReceiveTimeout = new TimeSpan(0, 1, 0),
19
                SendTimeout = new TimeSpan(0, 1, 0),
20
                TransactionFlow = false,
21
                TransferMode = TransferMode.Buffered,
22
                TransactionProtocol = TransactionProtocol.OleTransactions,
23
                HostNameComparisonMode = HostNameComparisonMode.StrongWildcard,
24
                MaxBufferPoolSize = 524288,
25
                MaxBufferSize = 65536,
26
                MaxConnections = 10,
27
                MaxReceivedMessageSize = 65536,
28
                Security = new NetNamedPipeSecurity
29
                {
30
                    Mode = NetNamedPipeSecurityMode.Transport,
31
                    Transport = new NamedPipeTransportSecurity { ProtectionLevel = System.Net.Security.ProtectionLevel.EncryptAndSign }
32
                }
33
            };
34
35
            return binding;
36
        }
37
    }
38
}
클립보드 이미지 추가 (최대 크기: 500 MB)