Project

General

Profile

Actions

Bug #5931

closed

Api does not fail on bad JSON

Added by François ARMAND almost 10 years ago. Updated over 6 years ago.

Status:
Released
Priority:
3
Category:
API
Target version:
Severity:
Minor - inconvenience | misleading | easy workaround
UX impact:
User visibility:
Operational - other Techniques | Technique editor | Rudder settings
Effort required:
Priority:
28
Name check:
Fix check:
Regression:

Description

The Rudder API does not fail when you give it a bad formatted JSON.

The result is that we are thinking it's not a JSON request, and try to parse it as "normal" -d parameters, and don't find anything relevant, so we don't change anything.

This make testing and undertanding API usage extremelly infuriating.


Related issues 1 (0 open1 closed)

Related to Rudder - Bug #5786: You cannot pass 'include' / 'exclude' targets as json for Rule API ReleasedVincent MEMBRÉ2014-11-19Actions
Actions #1

Updated by François ARMAND almost 10 years ago

From a technical point of view, we are using lift JsonPost that takes in charge to checking if the parameter is valid json, and is not executed if not.

We should certainly use JsonReq like in http://exploring.liftweb.net/master/index-15.html, and check by ourselve if the JSON is correct.

Actions #2

Updated by Vincent MEMBRÉ almost 10 years ago

  • Target version changed from 2.10.8 to 2.10.9
Actions #3

Updated by Vincent MEMBRÉ almost 10 years ago

  • Target version changed from 2.10.9 to 2.10.10
Actions #4

Updated by Vincent MEMBRÉ almost 10 years ago

  • Target version changed from 2.10.10 to 2.10.11
Actions #5

Updated by Vincent MEMBRÉ over 9 years ago

  • Target version changed from 2.10.11 to 2.10.12
Actions #6

Updated by Vincent MEMBRÉ over 9 years ago

  • Target version changed from 2.10.12 to 2.10.13
Actions #7

Updated by Benoît PECCATTE over 9 years ago

  • Status changed from 8 to New
Actions #8

Updated by Vincent MEMBRÉ over 9 years ago

  • Target version changed from 2.10.13 to 2.10.14
Actions #9

Updated by Vincent MEMBRÉ over 9 years ago

  • Target version changed from 2.10.14 to 2.10.15
Actions #10

Updated by Vincent MEMBRÉ over 9 years ago

  • Target version changed from 2.10.15 to 2.10.16
Actions #11

Updated by Vincent MEMBRÉ over 9 years ago

  • Target version changed from 2.10.16 to 2.10.17
Actions #12

Updated by Vincent MEMBRÉ about 9 years ago

  • Target version changed from 2.10.17 to 2.10.18
Actions #13

Updated by Vincent MEMBRÉ about 9 years ago

  • Target version changed from 2.10.18 to 2.10.19
Actions #14

Updated by Vincent MEMBRÉ about 9 years ago

  • Target version changed from 2.10.19 to 2.10.20
Actions #15

Updated by Vincent MEMBRÉ almost 9 years ago

  • Target version changed from 2.10.20 to 277
Actions #16

Updated by Vincent MEMBRÉ almost 9 years ago

  • Target version changed from 277 to 2.11.18
Actions #17

Updated by Vincent MEMBRÉ almost 9 years ago

  • Target version changed from 2.11.18 to 2.11.19
Actions #18

Updated by Vincent MEMBRÉ over 8 years ago

  • Target version changed from 2.11.19 to 2.11.20
Actions #19

Updated by Vincent MEMBRÉ over 8 years ago

  • Target version changed from 2.11.20 to 2.11.21
Actions #20

Updated by Vincent MEMBRÉ over 8 years ago

  • Target version changed from 2.11.21 to 2.11.22
Actions #21

Updated by Vincent MEMBRÉ over 8 years ago

  • Target version changed from 2.11.22 to 2.11.23
Actions #22

Updated by Vincent MEMBRÉ over 8 years ago

  • Target version changed from 2.11.23 to 2.11.24
Actions #23

Updated by Vincent MEMBRÉ about 8 years ago

  • Target version changed from 2.11.24 to 308
Actions #24

Updated by Vincent MEMBRÉ about 8 years ago

  • Target version changed from 308 to 3.1.14
Actions #25

Updated by Vincent MEMBRÉ about 8 years ago

  • Target version changed from 3.1.14 to 3.1.15
Actions #26

Updated by Vincent MEMBRÉ about 8 years ago

  • Target version changed from 3.1.15 to 3.1.16
Actions #27

Updated by Vincent MEMBRÉ about 8 years ago

  • Target version changed from 3.1.16 to 3.1.17
Actions #28

Updated by Vincent MEMBRÉ almost 8 years ago

  • Target version changed from 3.1.17 to 3.1.18
Actions #29

Updated by Vincent MEMBRÉ almost 8 years ago

  • Target version changed from 3.1.18 to 3.1.19
Actions #30

Updated by François ARMAND over 7 years ago

  • Severity set to Minor - inconvenience | misleading | easy workaround
  • User visibility set to Operational - other Techniques | Technique editor | Rudder settings
  • Priority set to 0
Actions #31

Updated by Vincent MEMBRÉ over 7 years ago

  • Target version changed from 3.1.19 to 3.1.20
Actions #32

Updated by Vincent MEMBRÉ over 7 years ago

  • Target version changed from 3.1.20 to 3.1.21
Actions #33

Updated by Vincent MEMBRÉ over 7 years ago

  • Target version changed from 3.1.21 to 3.1.22
Actions #34

Updated by Benoît PECCATTE over 7 years ago

  • Priority changed from 0 to 14
Actions #35

Updated by Benoît PECCATTE over 7 years ago

  • Priority changed from 14 to 27
Actions #36

Updated by Vincent MEMBRÉ over 7 years ago

  • Target version changed from 3.1.22 to 3.1.23
Actions #37

Updated by Vincent MEMBRÉ about 7 years ago

  • Target version changed from 3.1.23 to 3.1.24
Actions #38

Updated by Vincent MEMBRÉ about 7 years ago

  • Target version changed from 3.1.24 to 3.1.25
Actions #39

Updated by Vincent MEMBRÉ almost 7 years ago

  • Target version changed from 3.1.25 to 387
Actions #40

Updated by Vincent MEMBRÉ almost 7 years ago

  • Target version changed from 387 to 4.1.10
Actions #41

Updated by François ARMAND almost 7 years ago

  • Status changed from New to In progress
  • Assignee set to François ARMAND
  • Priority changed from 27 to 28
Actions #42

Updated by François ARMAND almost 7 years ago

  • Status changed from In progress to Pending technical review
  • Assignee changed from François ARMAND to Vincent MEMBRÉ
  • Pull Request set to https://github.com/Normation/rudder/pull/1856
Actions #43

Updated by Rudder Quality Assistant almost 7 years ago

  • Assignee changed from Vincent MEMBRÉ to François ARMAND
Actions #44

Updated by François ARMAND almost 7 years ago

  • Status changed from Pending technical review to Pending release
Actions #46

Updated by Vincent MEMBRÉ over 6 years ago

  • Status changed from Pending release to Released

This bug has been fixed in Rudder 4.1.10 and 4.2.4 which were released today.

Actions

Also available in: Atom PDF