|
|
|
|
12
|
)
|
12
|
)
|
13
|
|
13
|
|
14
|
var upgrader = websocket.Upgrader{
|
14
|
var upgrader = websocket.Upgrader{
|
15
|
- ReadBufferSize: 1024,
|
|
|
16
|
- WriteBufferSize: 1024,
|
|
|
|
|
15
|
+ ReadBufferSize: 2048,
|
|
|
16
|
+ WriteBufferSize: 2048,
|
17
|
// If a WS session contains sensitive information, and you choose to use
|
17
|
// If a WS session contains sensitive information, and you choose to use
|
18
|
// cookies for authentication (during the HTTP(S) upgrade request), then
|
18
|
// cookies for authentication (during the HTTP(S) upgrade request), then
|
19
|
// you should check that Origin is a domain under your control. If it
|
19
|
// you should check that Origin is a domain under your control. If it
|