|
6 | 6 |
|
7 | 7 | [Solved Issues](https://github.com/basemate/matestack-ui-core/issues?q=is%3Aissue+is%3Aclosed+milestone%3A0.7.4)
|
8 | 8 |
|
| 9 | +### Security Fixes |
| 10 | + |
| 11 | +XSS/Script injection vulnerablilty fixed in 0.7.4 |
| 12 | + |
| 13 | +* matestack-ui-core was vulnerable to XSS/Script injection |
| 14 | +* matestack-ui-core did not excape strings by default and did not cover this in the docs |
| 15 | +* matestack-ui-core should have escaped strings by default in order to prevent XSS/Script injection vulnerability |
| 16 | +* 0.7.4 fixes that by performing string escaping by default now |
| 17 | +* a new component `unescaped` (like `plain` before) allows to render unsecaped strings, but forces the developer to explicitly make a concious decision about that |
| 18 | + |
| 19 | +```ruby |
| 20 | +class Pages::MyApp::MyExamplePage < Matestack::Ui::Page |
| 21 | + |
| 22 | + class FakeUser < Struct.new(:name) |
| 23 | + end |
| 24 | + |
| 25 | + def prepare |
| 26 | + @user = FakeUser.new("<script>alert('such hack many wow')</script>") |
| 27 | + end |
| 28 | + |
| 29 | + def response |
| 30 | + components { |
| 31 | + div do |
| 32 | + heading size: 1, text: "Hello #{@user.name}" # was not escaped , from 0.7.4 on it's escaped |
| 33 | + plain "Hello #{@user.name}" # was not escaped, from 0.7.4 on it's escaped |
| 34 | + unescaped "Hello #{@user.name}" # is not escaped, as intended |
| 35 | + end |
| 36 | + } |
| 37 | + end |
| 38 | +end |
| 39 | + |
| 40 | +``` |
| 41 | + |
| 42 | +Affected Versions |
| 43 | + |
| 44 | +<= 0.7.3 |
| 45 | + |
| 46 | +Patched Versions |
| 47 | + |
| 48 | +>= 0.7.4 --> please update! |
| 49 | +
|
| 50 | +Workarounds |
| 51 | + |
| 52 | +escape string explicitly/manually |
| 53 | + |
| 54 | +reported by @PragTob |
| 55 | + |
9 | 56 | ### Improvements
|
10 | 57 |
|
11 | 58 | * On form submit, matestack form values are reset to previous values by fiedl
|
| 59 | + |
12 | 60 | --> The form component now does not reset itself when using `put`
|
| 61 | + |
13 | 62 | --> The reset behavior can now be configured (described in `form` component docs)
|
14 | 63 |
|
15 | 64 | * Dockerized core dev and test environment by jonasjabari
|
| 65 | + |
16 | 66 | --> easy local dev and test setup, cross-platform default for dev and testing
|
| 67 | + |
17 | 68 | --> CI is configured to run tests via dockerized test suite; same as local testing and good base for matrix testing (upcoming)
|
| 69 | + |
18 | 70 | --> Usage described in contribution docs
|
19 | 71 |
|
20 | 72 | * Add `follow_response` option to action component by fiedl
|
| 73 | + |
21 | 74 | --> same behavior enhancement as added to the `form` component in 0.7.3
|
| 75 | + |
22 | 76 | --> server may now decide where the transition should navigate to
|
| 77 | + |
23 | 78 | --> described in `action` component docs
|
24 | 79 |
|
25 | 80 | * Add confirm option to action component by fiedl
|
| 81 | + |
26 | 82 | --> easily add confirmation before performing an action
|
| 83 | + |
27 | 84 | --> prevent unintended delete action for example
|
| 85 | + |
28 | 86 | --> described in `action` component docs
|
29 | 87 |
|
30 | 88 | * New webpacker features by fiedl
|
| 89 | + |
31 | 90 | * make webpacker create es5 code instead of es6 code
|
| 91 | + |
32 | 92 | * Switch to Vue Production Mode if RAILS_ENV=staging or production
|
| 93 | + |
33 | 94 | * Establish webpack(er) and asset-pipeline workflows
|
34 | 95 |
|
35 | 96 | --> webpacker now builds assets for asset pipline usage AND webpacker usage (both usage approaches are described in the installation docs)
|
| 97 | + |
36 | 98 | --> webpacker now builds minified versions of matestack-ui-core.js (great improvement in file size!)
|
| 99 | + |
37 | 100 | --> webpacker now builds es5 code, which is compatible with IE11
|
| 101 | + |
38 | 102 | --> when used via asset pipeline, the minified version of matestack-ui-core together with the production build of vue.js is automatically required
|
39 |
| ---> when used via webpacker, matestack-ui-core can be used within a modern javascript workflow, importing and extending single matestack module for example |
| 103 | + |
| 104 | +--> when used via webpacker, matestack-ui-core can be used within a modern javascript workflow, importing and extending |
| 105 | +single matestack module for example |
40 | 106 |
|
41 | 107 | * New components
|
42 | 108 | * Add HTML `<picture>` tag to core components by pascalwengerter
|
|
0 commit comments