Project:
View Issue Details[ Jump to Notes ] | [ Issue History ] [ Print ] | |||||||
ID | ||||||||
0046572 | ||||||||
Type | Category | Severity | Reproducibility | Date Submitted | Last Update | |||
defect | [Openbravo ERP] A. Platform | minor | have not tried | 2021-05-07 10:13 | 2021-05-10 08:22 | |||
Reporter | alostale | View Status | public | |||||
Assigned To | alostale | |||||||
Priority | normal | Resolution | fixed | Fixed in Version | PR21Q3 | |||
Status | closed | Fix in branch | Fixed in SCM revision | |||||
Projection | none | ETA | none | Target Version | ||||
OS | Any | Database | Any | Java version | ||||
OS Version | Database version | Ant version | ||||||
Product Version | SCM revision | |||||||
Merge Request Status | approved | |||||||
Review Assigned To | ||||||||
OBNetwork customer | No | |||||||
Web browser | ||||||||
Modules | Core | |||||||
Support ticket | ||||||||
Regression level | ||||||||
Regression date | ||||||||
Regression introduced in release | ||||||||
Regression introduced by commit | ||||||||
Triggers an Emergency Pack | No | |||||||
Summary | 0046572: ws tests fail having modules in development | |||||||
Description | Having modules in development, some web service junit tests fail due to incorrect CSRF token management. | |||||||
Steps To Reproduce | 1. Set core in developemnt 2. start tomcat 3. run DataSourceSecurity ERROR: 10:10:47.003 INFO org.openbravo.test.base.OBBaseTest - *** Starting test case: org.openbravo.test.datasource.DataSourceSecurity.fetchShouldBeAllowedOnlyIfRoleIsGranted[ADMIN_ROLE - dataSource: ProductByPriceAndWarehouse] 10:10:47.213 ERROR org.openbravo.test.datasource.BaseDataSourceTestDal - Cannot retrieve CSRF Token java.lang.Exception: Cannot find CSRF Token in SessionDynamic response at org.openbravo.test.datasource.BaseDataSourceTestDal.findCsrfTokenInResponse(BaseDataSourceTestDal.java:125) ~[classes/:?] at org.openbravo.test.datasource.BaseDataSourceTestDal.getTokenFromSessionDynamic(BaseDataSourceTestDal.java:111) [classes/:?] | |||||||
Tags | No tags attached. | |||||||
Attached Files | ||||||||
![]() |
|
![]() |
|
(0127883) hgbot (developer) 2021-05-07 10:23 |
Merge Request created: https://gitlab.com/openbravo/product/openbravo/-/merge_requests/357 [^] |
(0127924) hgbot (developer) 2021-05-10 08:22 |
Merge request merged: https://gitlab.com/openbravo/product/openbravo/-/merge_requests/357 [^] |
(0127925) hgbot (developer) 2021-05-10 08:22 |
Directly closing issue as related merge request is already approved. Repository: https://gitlab.com/openbravo/product/openbravo [^] Changeset: 60751f1a3940d74af82316ed8efdf1c31c0bea37 Author: Asier Lostalé <asier.lostale@openbravo.com> Date: 2021-05-10T07:07:16+02:00 URL: https://gitlab.com/openbravo/product/openbravo/-/commit/60751f1a3940d74af82316ed8efdf1c31c0bea37 [^] fixes BUG-46572: ws tests fail having modules in development When not having modules in development the response of the request to get the CSRF token is minified. Test making use of it looked for the token assuming it was minified making it fail when it was not. The regexp to look for the token has been extended to allow optional blank spaces, also it has been simplified getting in a group directly the token value instead of parsing it afterward. --- M src-test/src/org/openbravo/test/datasource/BaseDataSourceTestDal.java --- |
![]() |
|||
Date Modified | Username | Field | Change |
2021-05-07 10:13 | alostale | New Issue | |
2021-05-07 10:13 | alostale | Assigned To | => platform |
2021-05-07 10:13 | alostale | OBNetwork customer | => No |
2021-05-07 10:13 | alostale | Modules | => Core |
2021-05-07 10:13 | alostale | Triggers an Emergency Pack | => No |
2021-05-07 10:13 | alostale | Assigned To | platform => alostale |
2021-05-07 10:23 | hgbot | Merge Request Status | => open |
2021-05-07 10:23 | hgbot | Note Added: 0127883 | |
2021-05-10 08:22 | hgbot | Merge Request Status | open => approved |
2021-05-10 08:22 | hgbot | Resolution | open => fixed |
2021-05-10 08:22 | hgbot | Status | new => closed |
2021-05-10 08:22 | hgbot | Note Added: 0127924 | |
2021-05-10 08:22 | hgbot | Fixed in Version | => PR21Q3 |
2021-05-10 08:22 | hgbot | Note Added: 0127925 |
Copyright © 2000 - 2009 MantisBT Group |