Skip to content

Commit 515c5f5

Browse files
authored
Increase gRPC max message size from 4MB to 10MB (#370)
1 parent 695e2c3 commit 515c5f5

File tree

14 files changed

+270065
-12
lines changed

14 files changed

+270065
-12
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,25 +39,25 @@ Prerequisites:
3939

4040
##### x86_64
4141
```
42-
rpm -Uvh --oldpackage https://github.com/AikidoSec/firewall-php/releases/download/v1.4.9/aikido-php-firewall.x86_64.rpm
42+
rpm -Uvh --oldpackage https://github.com/AikidoSec/firewall-php/releases/download/v1.4.10/aikido-php-firewall.x86_64.rpm
4343
```
4444

4545
##### arm64 / aarch64
4646
```
47-
rpm -Uvh --oldpackage https://github.com/AikidoSec/firewall-php/releases/download/v1.4.9/aikido-php-firewall.aarch64.rpm
47+
rpm -Uvh --oldpackage https://github.com/AikidoSec/firewall-php/releases/download/v1.4.10/aikido-php-firewall.aarch64.rpm
4848
```
4949

5050
#### For Debian-based Systems (Debian, Ubuntu)
5151

5252
##### x86_64
5353
```
54-
curl -L -O https://github.com/AikidoSec/firewall-php/releases/download/v1.4.9/aikido-php-firewall.x86_64.deb
54+
curl -L -O https://github.com/AikidoSec/firewall-php/releases/download/v1.4.10/aikido-php-firewall.x86_64.deb
5555
dpkg -i -E ./aikido-php-firewall.x86_64.deb
5656
```
5757

5858
##### arm64 / aarch64
5959
```
60-
curl -L -O https://github.com/AikidoSec/firewall-php/releases/download/v1.4.9/aikido-php-firewall.aarch64.deb
60+
curl -L -O https://github.com/AikidoSec/firewall-php/releases/download/v1.4.10/aikido-php-firewall.aarch64.deb
6161
dpkg -i -E ./aikido-php-firewall.aarch64.deb
6262
```
6363

docs/aws-elastic-beanstalk.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
```
55
commands:
66
aikido-php-firewall:
7-
command: "rpm -Uvh --oldpackage https://github.com/AikidoSec/firewall-php/releases/download/v1.4.9/aikido-php-firewall.x86_64.rpm"
7+
command: "rpm -Uvh --oldpackage https://github.com/AikidoSec/firewall-php/releases/download/v1.4.10/aikido-php-firewall.x86_64.rpm"
88
ignoreErrors: true
99
1010
files:

docs/fly-io.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ Create a script to install the Aikido PHP Firewall during deployment:
3232
#!/usr/bin/env bash
3333
cd /tmp
3434

35-
curl -L -O https://github.com/AikidoSec/firewall-php/releases/download/v1.4.9/aikido-php-firewall.x86_64.deb
35+
curl -L -O https://github.com/AikidoSec/firewall-php/releases/download/v1.4.10/aikido-php-firewall.x86_64.deb
3636
dpkg -i -E ./aikido-php-firewall.x86_64.deb
3737
```
3838

docs/laravel-forge.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ You can get your token from the [Aikido Security Dashboard](https://help.aikido.
88

99
Go to "Commands" and run the following by replacing the sudo password with the one that Forge displays when the server is created:
1010
```
11-
curl -L -O https://github.com/AikidoSec/firewall-php/releases/download/v1.4.9/aikido-php-firewall.x86_64.deb && echo "YOUR_SUDO_PASSWORD_HERE" | sudo -S dpkg -i -E ./aikido-php-firewall.x86_64.deb && echo "YOUR_SUDO_PASSWORD_HERE" | sudo -S service php8.4-fpm restart
11+
curl -L -O https://github.com/AikidoSec/firewall-php/releases/download/v1.4.10/aikido-php-firewall.x86_64.deb && echo "YOUR_SUDO_PASSWORD_HERE" | sudo -S dpkg -i -E ./aikido-php-firewall.x86_64.deb && echo "YOUR_SUDO_PASSWORD_HERE" | sudo -S service php8.4-fpm restart
1212
```
1313

1414
![Forge Commands](./forge-commands.png)

lib/agent/constants/constants.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package constants
22

33
const (
4-
Version = "1.4.9"
4+
Version = "1.4.10"
55
SocketPath = "/run/aikido-" + Version + "/aikido-agent.sock"
66
PidPath = "/run/aikido-" + Version + "/aikido-agent.pid"
77
ConfigUpdatedAtMethod = "GET"

lib/agent/grpc/server.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,10 @@ func (s *GrpcServer) OnMonitoredUserAgentMatch(ctx context.Context, req *protos.
174174
var grpcServer *grpc.Server
175175

176176
func StartServer(lis net.Listener) {
177-
grpcServer = grpc.NewServer() //grpc.MaxConcurrentStreams(100)
177+
grpcServer = grpc.NewServer(
178+
grpc.MaxRecvMsgSize(10*1024*1024), // 10MB max receive message size
179+
grpc.MaxSendMsgSize(10*1024*1024), // 10MB max send message size
180+
)
178181
protos.RegisterAikidoServer(grpcServer, &GrpcServer{})
179182

180183
log.Infof(log.MainLogger, "gRPC server is running on Unix socket %s", constants.SocketPath)

lib/php-extension/include/php_aikido.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
extern zend_module_entry aikido_module_entry;
44
#define phpext_aikido_ptr &aikido_module_entry
55

6-
#define PHP_AIKIDO_VERSION "1.4.9"
6+
#define PHP_AIKIDO_VERSION "1.4.10"
77

88
#if defined(ZTS) && defined(COMPILE_DL_AIKIDO)
99
ZEND_TSRMLS_CACHE_EXTERN()

lib/request-processor/globals/globals.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,6 @@ func CreateServer(token string) *ServerData {
6262
}
6363

6464
const (
65-
Version = "1.4.9"
65+
Version = "1.4.10"
6666
SocketPath = "/run/aikido-" + Version + "/aikido-agent.sock"
6767
)

lib/request-processor/grpc/client.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@ func Init() {
2323
conn, err := grpc.Dial(
2424
"unix://"+globals.SocketPath,
2525
grpc.WithTransportCredentials(insecure.NewCredentials()),
26+
grpc.WithDefaultCallOptions(
27+
grpc.MaxCallRecvMsgSize(10*1024*1024), // 10MB max receive message size
28+
grpc.MaxCallSendMsgSize(10*1024*1024)), // 10MB max receive message size
2629
)
2730

2831
if err != nil {

package/rpm/aikido.spec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
Name: aikido-php-firewall
2-
Version: 1.4.9
2+
Version: 1.4.10
33
Release: 1
44
Summary: Aikido PHP Extension
55
License: GPL

0 commit comments

Comments
 (0)