JimMoen
892becb5bf
fix(rule_engine): rule_id and resource_id in path urlencoded
2022-10-27 00:39:13 +08:00
firest
e66e563648
fix(logger): add new macro `?LOG_SENSITIVE` and use it to replace some `?LOG` for security reason
...
some arguments passed to external API may contain sensitive data, when the API execution fails, sensitive data may be returned as a part of the failure reason, if this reason printed to the log, it will lead to sensitive data leakage, so we should check carefully and scan these failed returns
2022-10-26 17:14:46 +08:00
Zaiming (Stone) Shi
f5c0ef3e56
Merge pull request #9226 from zmstone/1025-fix-drop-tuple-value-message-headers
...
fix(emqx_rule_events): do not keep tuple-value message headers
2022-10-26 09:59:12 +02:00
Xinyu Liu
7f63912bba
Merge pull request #9224 from terry-xiaoyu/utf8_backup_filenames
...
fix: list exported json files failed with utf8 filenames
2022-10-26 15:47:00 +08:00
Zaiming (Stone) Shi
81e6a40454
fix(emqx_rule_events): do not keep tuple-value message headers
...
the converted message is for JSON encoding, keeping the tuple-values
will lead to encoding error.
2022-10-26 08:52:20 +02:00
Zaiming (Stone) Shi
c6067447ac
chore: sync changes back from ee to ce
2022-10-26 08:49:52 +02:00
Xinyu Liu
90ef9254fd
Merge pull request #9199 from terry-xiaoyu/boot_blocked_by_unreachable_resources
...
fix: refresh resources and rules asynchronously
2022-10-26 13:41:07 +08:00
Shawn
fa333157eb
fix: list exported json files failed with utf8 filenames
2022-10-26 11:46:45 +08:00
Zaiming (Stone) Shi
51c73eed55
Merge pull request #9044 from HJianBo/fix-jwt-acl-rules
...
fix(acl): support all rules in JWT ACL
2022-10-25 20:33:22 +02:00
Shawn
006d2e5f29
fix: rolling upgrade failed on undef funcs
2022-10-25 20:41:31 +08:00
Thales Macedo Garitezi
c0b5b887c3
fix(mgmt_api): return 503 when emqx is not running in `/status`
2022-10-24 14:22:28 -03:00
JianBo He
bd59197a58
chore: apply suggestions from code review
...
Co-authored-by: Zaiming (Stone) Shi <zmstone@gmail.com>
2022-10-24 16:28:25 +08:00
JianBo He
4a9b5662f8
chore: fix diaylzer warnings
2022-10-24 09:51:05 +08:00
Shawn
15248eb069
chore: update the change log
2022-10-21 15:41:00 +08:00
Shawn
2c61f92eec
fix: refresh resources and rules asynchronously
2022-10-21 15:06:35 +08:00
JianBo He
b9e9540120
chore(auth): support printing unicode string
2022-10-21 11:59:01 +08:00
JianBo He
38e87579c0
chore(jwt-acl): avoid the disruptions caused by rule formatting errors
2022-10-21 11:47:19 +08:00
JianBo He
fa4203effa
chore: apply suggestions from code review
...
Co-authored-by: Zaiming (Stone) Shi <zmstone@gmail.com>
2022-10-21 11:47:19 +08:00
JianBo He
7b0acf2c4d
chore: update changes and appup.src
2022-10-21 11:47:07 +08:00
JianBo He
1857fe643a
fix(acl): support all rules in JWT ACL
2022-10-21 11:44:48 +08:00
Shawn
bfe238fa1c
fix: set precision of counter 'max_speed' to 2 digits
2022-10-21 09:05:25 +08:00
JianBo He
8e199b3a77
chore: update appup.src
2022-10-20 15:52:17 +08:00
JianBo He
317ef65c7e
chore: remove the duplicated clientid print in log
2022-10-20 15:50:04 +08:00
JianBo He
4cf3d181d8
chore(auth-http): more infos for auth/acl checking failure
2022-10-20 15:48:58 +08:00
Zaiming (Stone) Shi
5bc822cc78
chore: delete duplicated module from appup
2022-10-17 12:55:22 +02:00
Zaiming (Stone) Shi
11026b7644
chore: re-generate appup for v4.3.22
2022-10-16 08:43:45 +02:00
Zaiming (Stone) Shi
20e0d14026
chore: bump app versions
2022-10-15 15:01:57 +02:00
Zaiming (Stone) Shi
1ba2c01f25
Merge remote-tracking branch 'origin/release-v43' into main-v4.3
2022-10-15 14:58:22 +02:00
Xinyu Liu
265fab8ccf
Merge pull request #9150 from terry-xiaoyu/port_rule_metrics_fix_to_release_v43
...
fix: reset rule metrics crashed under certain conditions
2022-10-14 16:05:23 +08:00
Shawn
381c56d52f
fix: reset rule metrics crashed under certain conditions
2022-10-14 10:50:39 +08:00
Ilya Averyanov
53bc2d9d58
fix(jwt): restore legacy emqx_auth_jwt hook interface
2022-10-13 11:37:50 +03:00
Ivan Dyachkov
73d72eacce
fix: demote rate limit log level to notice
2022-10-11 13:05:21 +02:00
JimMoen
7f92c29ada
chore: bump appup.src for `emqx_rule_funcs.erl`
2022-10-11 13:45:11 +08:00
JimMoen
3e8c070b59
Revert "fix: rm unused module"
...
This reverts commit 267946c379
.
Revert it temporary, we need fix `scripts/update-appup.sh` later.
It only compares the current release with its predecessor.
2022-10-11 13:44:34 +08:00
JimMoen
5047211950
test: rulesql select fields and select from event message
2022-10-11 13:44:34 +08:00
JimMoen
27e19da066
test(rulesql): num funcs type cases
2022-10-11 13:44:34 +08:00
JimMoen
32376c7cf9
fix(rule_func): refine num funcs error info type unsupported
2022-10-11 11:23:25 +08:00
JimMoen
0a5a0867e4
fix(rule_func): refine `+` error info when type implicit conversion
2022-10-11 11:23:25 +08:00
JimMoen
d8a022fb45
fix(test): unstopped test client
2022-10-11 11:23:25 +08:00
JimMoen
267946c379
fix: rm unused module
...
`emqx_rule_date` was added before [v4.3.15-rc1]
PR: emqx#7894
commit: 8558a62ee2
The change was released in [v4.3.15-rc1] [v4.3.15-rc2]
And unused at [v4.3.15-rc3]
PR: emqx#8044
commit: 4fc5cb2817
We just keep the module from [v4.3.15-rc1] to [v4.3.20] and remove this module in newer version
2022-10-11 11:23:25 +08:00
JimMoen
fd7230353c
refactor(test): move rule_engine sql test cases into a separate file
2022-10-11 11:23:25 +08:00
Shawn
6d52f908d1
chore: update emqx_rule_engine.appup.src
2022-10-10 17:24:27 +08:00
Shawn
338b11ab95
fix: cannot reset metrics for fallback actions
2022-10-10 17:13:39 +08:00
JianBo He
bc68f60bb5
chore: update appup.src
2022-10-09 17:52:59 +08:00
JianBo He
68dd29420d
chore: fix duplicated variable name
2022-10-09 17:43:30 +08:00
JianBo He
e5a673376f
refactor: support the retry option
2022-10-09 17:27:38 +08:00
Xinyu Liu
505507139e
Merge pull request #9079 from terry-xiaoyu/some_issues_in_rule_engine
...
Some issues in rule engine
2022-10-09 14:32:39 +08:00
JianBo He
92d5caf908
Merge branch 'main-v4.3' into test/mqtt_sn
2022-10-08 14:28:01 +08:00
Shawn
1bb7c23db1
fix: discard the 'id' field when testing a resource
2022-10-08 10:50:42 +08:00
Zaiming (Stone) Shi
f24728ee7b
chore: sync diverged modules modules from ee back to ce
2022-10-05 14:59:18 -03:00
Ivan Dyachkov
c9ff67a637
chore: add timetrap of 2 mins for pgsql test cases
2022-10-05 15:53:55 +02:00
Shawn
ab3ec9c176
chore: update the appup.src
2022-09-30 16:32:52 +08:00
Zaiming (Stone) Shi
07f0f0a5f8
Merge remote-tracking branch 'origin/release-v43' into 0921-build-merge-release-br-back-to-main-asap
2022-09-29 10:56:45 +02:00
Shawn
7d2dd3d37d
fix: deny POST an existing resource
2022-09-29 13:41:02 +08:00
Shawn
29c76d16d7
fix: reset rule metrics crash if it has not initialized
2022-09-29 13:40:01 +08:00
Thales Macedo Garitezi
2e0eae54f8
fix(acl): check ACL before publishing last will testament (lwt) message (4.3)
2022-09-26 15:22:29 -03:00
Thales Macedo Garitezi
a61c97ed9b
test: attempt to reduce inter-testcase flakiness in CI
...
Ex:
```
=== ERROR! init_per_testcase crashed!
Location: [{emqx_auth_mongo_SUITE,'-init_mongo_data/0-fun-0-',207},
{emqx_auth_mongo_SUITE,init_mongo_data,207},
{emqx_auth_mongo_SUITE,init_per_testcase,177},
{test_server,do_init_per_testcase,1554},
{test_server,run_test_case_eval1,1255},
{test_server,run_test_case_eval,1225}]
Reason: {{assertMatch,[{module,emqx_auth_mongo_SUITE},
{line,207},
{expression,"mongo_api : insert ( Connection , ? MONGO_CL_USER , ? INIT_AUTH )"},
{pattern,"{ { true , _ } , _ }"},
{value,{error,timeout}}]},
[{emqx_auth_mongo_SUITE,'-init_mongo_data/0-fun-0-',1,
[{file,"/emqx/apps/emqx_auth_mongo/test/emqx_auth_mongo_SUITE.erl"},
{line,207}]},
{emqx_auth_mongo_SUITE,init_mongo_data,0,
[{file,"/emqx/apps/emqx_auth_mongo/test/emqx_auth_mongo_SUITE.erl"},
{line,207}]},
{emqx_auth_mongo_SUITE,init_per_testcase,2,
[{file,"/emqx/apps/emqx_auth_mongo/test/emqx_auth_mongo_SUITE.erl"},
{line,177}]},
{test_server,do_init_per_testcase,2,[{file,"test_server.erl"},{line,1554}]},
{test_server,run_test_case_eval1,6,[{file,"test_server.erl"},{line,1255}]},
{test_server,run_test_case_eval,9,[{file,"test_server.erl"},{line,1225}]}]}
```
2022-09-26 09:13:07 -03:00
Thales Macedo Garitezi
7c4842e6e5
test: attempt to fix inter-suite flakiness
...
Ex:
https://github.com/emqx/emqx-enterprise/actions/runs/3124750818/jobs/5068407612#step:7:769
```
%%% undefined ==> end_per_suite: FAILED
%%% undefined ==> {{badmatch,{error,enoent}},
[{emqx_auth_mongo_SUITE,end_per_suite,1,
[{file,"/emqx/apps/emqx_auth_mongo/test/emqx_auth_mongo_SUITE.erl"},
{line,62}]},
{test_server,ts_tc,3,[{file,"test_server.erl"},{line,1784}]},
{test_server,run_test_case_eval1,6,[{file,"test_server.erl"},{line,1381}]},
{test_server,run_test_case_eval,9,[{file,"test_server.erl"},{line,1225}]}]}
Testing lib.emqx_auth_mongo: TEST COMPLETE, 3 ok, 0 failed of 3 test cases
```
2022-09-26 08:57:53 -03:00
firest
1e00345777
chore(emqx_sn): bump version && update appup
2022-09-26 18:00:04 +08:00
firest
0a3c8d035c
fix(mqtt_sn): after receiving publish in `idle mode` the gateway may panic
...
the `emqx_sn_gateway` will return `{keep_state, Timeout}` when received publish in `idle mode`, this is an incorrect format of `gen_statem` state return result, this return will replace the `state data` by the `Timeout`, the fix is to change it to `{keep_state_and_data, Timeout}`
2022-09-26 17:59:35 +08:00
firest
5b14d7f709
test(mqtt_sn): improve test coverage of `emqx_sn_gateway`
2022-09-26 16:37:33 +08:00
JianBo He
c05ce82933
refactor(psk): create the ets table in supervisor process
2022-09-23 11:16:31 +08:00
Thales Macedo Garitezi
f94c5ee40a
feat(auth_mongo): use `with_timeout` for `query`
2022-09-22 11:28:59 -03:00
Ilya Averyanov
7a26aae27b
chore(retainer): sync retainer from release-e43
2022-09-22 12:42:21 +03:00
firest
502f3e8d5c
test(mqtt_sn): improve test coverage to 90%
2022-09-22 17:31:08 +08:00
Thales Macedo Garitezi
90995069c6
chore(auth_mongo): bump appup
2022-09-21 14:46:17 -03:00
Thales Macedo Garitezi
a60763dfcf
test(mongo): attempt to improve test stability
2022-09-21 14:03:44 -03:00
Thales Macedo Garitezi
ea8f444bda
test(mongo): add more acl tests
...
With this commit, we reach 100 % coverage over `emqx_acl_mongo`.
2022-09-21 14:03:44 -03:00
Thales Macedo Garitezi
69659caaf8
test(mongo): add more coverage tests
...
reaching 100% coverage of `emqx_auth_mongo` with this.
2022-09-21 14:03:44 -03:00
Thales Macedo Garitezi
3f02c6b574
feat(mongo): add timeouts and more tests
2022-09-21 14:03:44 -03:00
Thales Macedo Garitezi
fe0ba87fd0
fix: handle interpolation of unavailable info
2022-09-20 14:15:32 -03:00
Thales Macedo Garitezi
d3304d49b5
test: increase mongo integration test coverage (4.3)
2022-09-20 14:15:32 -03:00
Zaiming (Stone) Shi
e6603548d7
chore: generate appups after bumped new version
2022-09-17 18:50:28 +02:00
Zaiming (Stone) Shi
bfb53b7f24
chore: bump app versions after merged tag v4.3.20
2022-09-16 12:56:51 +02:00
Zaiming (Stone) Shi
3c852098d7
Merge tag 'v4.3.20' into main-v4.3
2022-09-16 12:54:00 +02:00
JianBo He
89ed4a350f
chore: avoid generating crash logs for hook execution
2022-09-16 17:53:49 +08:00
zhongwencool
e4c2715842
fix: add ip to dashboard listener_on
2022-09-16 15:36:17 +08:00
Thales Macedo Garitezi
6204481d71
test: avoid inter-suite flakiness
...
This test runs most of the time fine in CI. But, if run alone
locally, will fail consistently because the default `acl.conf` has a
catch-all `{allow, all}` clause. Probably another suite that runs
before this in CI unloads that and everything seems fine.
2022-09-15 18:08:20 -03:00
Thales Macedo Garitezi
0599393741
Merge pull request #8942 from thalesmg/fix-ignore-dialyzer-pt1-43
...
chore: fix ignored dialyzer warnings (part 1) (4.3)
2022-09-14 14:56:59 -03:00
Thales Macedo Garitezi
6fc7df9c54
Merge pull request #8894 from thalesmg/bugfix-will-msg-authn-43
...
test: add test case for not publishing will msg when not authorized
2022-09-13 09:46:14 -03:00
JianBo He
5592b1503d
Merge pull request #8908 from HJianBo/using-erlang-system-time
...
fix(time): replace os:system_time with erlang:system_time
2022-09-13 09:09:54 +08:00
Thales Macedo Garitezi
fa6c22b366
chore: update appups
2022-09-12 10:56:35 -03:00
Thales Macedo Garitezi
d72ca84af0
chore: fix ignored dialyzer warnings (part 1) (4.3)
2022-09-12 10:56:35 -03:00
Thales Macedo Garitezi
1f5103b390
test: add test case for not publishing will msg when not authorized
2022-09-12 09:04:54 -03:00
Zaiming (Stone) Shi
4597344881
Merge pull request #8941 from thalesmg/fix-appup-check-contains-re
...
ci(fix): fix check for appup coverage
2022-09-11 17:27:38 +02:00
Thales Macedo Garitezi
94afb633f8
chore: update missing appup instructions
2022-09-09 13:37:00 -03:00
Zaiming (Stone) Shi
2c54190479
fix: revert 'accepted' state of exproto plugin
2022-09-09 12:27:02 +02:00
Shawn
b9d75181e5
chore: update emqx_rule_engine.appup.src
2022-09-08 16:38:34 +08:00
Shawn
f0cc75d144
fix(sql): topic matching to null values should return false
2022-09-08 16:37:38 +08:00
JianBo He
0d5c32a706
fix(time): use erlang:system_time/0-1 consistently
...
Avoid the problem of inaccurate timers caused by mixing
erlang:system_time/0-1 and os:system_time/0-1
2022-09-08 15:46:44 +08:00
firest
d5494897c7
fix(jwt): make jwt support float timestamp claims
2022-09-06 11:51:39 +08:00
firest
884ec15567
fix(jwt): make binary_to_number function support list type
2022-09-01 17:05:39 +08:00
firest
a6cf74ea6f
chore: fix emqx_auth_jwt appup
2022-09-01 16:52:41 +08:00
firest
ddc25fc5c2
fix(jwt): simplify binary_to_number function
2022-09-01 16:27:15 +08:00
firest
c999b43144
chore: bump emqx_auth_jwt version && update appup
2022-09-01 15:48:14 +08:00
firest
15c84ba152
fix(jwt): support non-integer timestamp claims
2022-09-01 15:43:32 +08:00
Zaiming (Stone) Shi
51412e25c8
fix(emqx_rule_engine): fix rule update function
...
Prior to this change, the update of a rule will always try to
initialise the action because the 'enabled' flag is by default 'true'
2022-08-31 15:13:38 +02:00
Zaiming (Stone) Shi
6f28e0eb83
chore: update appup files
2022-08-31 08:07:42 +02:00
zhongwencool
e4992b8f59
chore: update mnesia_acl appup.src
2022-08-30 15:41:23 +08:00
zhongwencool
78ec03f23b
chore: add emqx_ctl acl list to show all acls
2022-08-30 15:03:21 +08:00