dify/api/core
-LAN- 04954918a5
Merge commit from fork
* fix(oraclevector): SQL Injection

Signed-off-by: -LAN- <laipz8200@outlook.com>

* fix(oraclevector): Remove bind variables from FETCH FIRST clause

Oracle doesn't support bind variables in the FETCH FIRST clause.
Fixed by using validated integers directly in the SQL string while
maintaining proper input validation to prevent SQL injection.

- Updated search_by_vector method to use validated top_k directly
- Updated search_by_full_text method to use validated top_k directly
- Adjusted parameter numbering for document_ids_filter placeholders

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>

---------

Signed-off-by: -LAN- <laipz8200@outlook.com>
Co-authored-by: Claude <noreply@anthropic.com>
2025-08-26 13:51:23 +08:00
..
agent Fix incorrect exception reference for `json.dumps()` (#24329) 2025-08-24 00:31:04 +08:00
app [Chore/Refactor] Use centralized naive_utc_now for UTC datetime operations (#24352) 2025-08-22 23:53:05 +08:00
base refactor: Remove RepositoryFactory (#19176) 2025-05-06 21:14:51 +08:00
callback_handler orm filter -> where (#22801) 2025-07-24 00:57:45 +08:00
entities feat: add multi model credentials (#24451) 2025-08-25 16:12:29 +08:00
errors fix(core/errors): change base class of custom exceptions to ValueError (#11955) 2024-12-22 10:41:34 +08:00
extension [CHORE]: x: T = None to x: Optional[T] = None (#24217) 2025-08-21 21:58:39 +08:00
external_data_tool make logging not use f-str, change others to f-str (#22882) 2025-07-25 10:32:48 +08:00
file fix the error of unable to retrieve url from file (#13603) 2025-08-02 17:15:55 +08:00
helper refactor: replace try-except blocks with contextlib.suppress for cleaner exception handling (#24284) 2025-08-21 18:18:49 +08:00
llm_generator hotfix: fix multiple case match syntax (#24204) 2025-08-20 14:45:46 +08:00
mcp [CHORE]: x: T = None to x: Optional[T] = None (#24217) 2025-08-21 21:58:39 +08:00
memory feat: If combining text and files, place the text prompt after the fi… (#23779) 2025-08-12 10:36:55 +08:00
model_runtime feat: add multi model credentials (#24451) 2025-08-25 16:12:29 +08:00
moderation Fix TypeError: object of type int has no len() (#24484) 2025-08-25 19:50:51 +08:00
ops Feat: External_trace_id compatible with OpenTelemetry (#23918) 2025-08-15 09:13:41 +08:00
plugin enhancing logging (#23332) 2025-08-05 10:36:48 +08:00
prompt Feat/chat message image first for agent and advanced_chat APP (#23796) 2025-08-22 16:42:15 +08:00
rag Merge commit from fork 2025-08-26 13:51:23 +08:00
repositories refactor: simplify repository factory with Django-style import_string (#24354) 2025-08-22 21:56:25 +08:00
tools example of remove some reflections (#24488) 2025-08-25 23:16:59 +08:00
variables fix: value_type check failed when updating variables (#24274) 2025-08-21 15:28:07 +08:00
workflow feat: If combining text and files, place the text prompt after the fi… (#24472) 2025-08-25 17:51:46 +08:00
__init__.py chore(api/core): apply ruff reformatting (#7624) 2024-09-10 17:00:20 +08:00
hosting_configuration.py chore(provider_manager): Update hosted model's name (#14334) 2025-02-25 18:47:33 +08:00
indexing_runner.py [Chore/Refactor] Use centralized naive_utc_now for UTC datetime operations (#24352) 2025-08-22 23:53:05 +08:00
model_manager.py make logging not use f-str, change others to f-str (#22882) 2025-07-25 10:32:48 +08:00
provider_manager.py feat: add multi model credentials (#24451) 2025-08-25 16:12:29 +08:00