nextcloud / nextcloud/updater

Check DB privileges

Open
#83 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement feature: upgrade low robustness 💪
Dominant language
PHP
Stars
51
Forks
40
Avg merge
2d 19h
Merged PRs (30d)
3

Description

Original reported by @kehugter in https://github.com/nextcloud/server/issues/2870

I keep my DB user with minimum privileges during normal usage for security reasons. The update using the updater app failed because of missing DROP and INDEX privileges.

Steps to reproduce
  1. Update using the updater app. Finish the first part successfully
  2. Return to the main site to finish updating the database
  3. Update fails because of missing DB privilleges
Expected behaviour

During the sanity check, the user is warned about insufficient DB privileges.

Actual behaviour

No DB privileges check is done, user gets an error message after the Nextcould instance is unusable.

Server configuration

Operating system:
Debian 8.6
Web server:
nginx
Database:
mysql
PHP version:
5.6.29
Nextcloud version: (see Nextcloud admin page)
10.0.2
Updated from an older Nextcloud/ownCloud or fresh install:
Updated from Nextcloud 10.0.1
Where did you install Nextcloud from:
tar archive

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing the updater's sanity-check and database-update flow, then reproduce the failure with a database user lacking DROP and INDEX privileges. Done means the sanity check detects insufficient privileges and warns before the update can leave the Nextcloud instance unusable.

Written by the indexing model from the issue text.

Assessment

Tech stack
mysql, php
Domain
backend, database
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.