* @param string $calendarUri
* @param array $properties
* @return int
- * @suppress SqlInjectionChecker
*/
public function createCalendar($principalUri, $calendarUri, array $properties) {
$values = [
$supportedProperties = array_keys($this->propertyMap);
$supportedProperties[] = '{' . Plugin::NS_CALDAV . '}schedule-calendar-transp';
- /**
- * @suppress SqlInjectionChecker
- */
$propPatch->handle($supportedProperties, function ($mutations) use ($calendarId) {
$newValues = [];
foreach ($mutations as $propertyName => $propertyValue) {
$supportedProperties = array_keys($this->subscriptionPropertyMap);
$supportedProperties[] = '{http://calendarserver.org/ns/}source';
- /**
- * @suppress SqlInjectionChecker
- */
$propPatch->handle($supportedProperties, function ($mutations) use ($subscriptionId) {
$newValues = [];
'{' . Plugin::NS_CARDDAV . '}addressbook-description',
];
- /**
- * @suppress SqlInjectionChecker
- */
$propPatch->handle($supportedProperties, function ($mutations) use ($addressBookId) {
$updates = [];
foreach ($mutations as $property => $newValue) {
* Get admin defined mounts
*
* @return array
- * @suppress SqlInjectionChecker
*/
public function getAdminMounts() {
$builder = $this->connection->getQueryBuilder();
* @param int $type any of the self::APPLICABLE_TYPE_ constants
* @param string|null $value user_id, group_id or null for global mounts
* @return array
- * @suppress SqlInjectionChecker
*/
public function getAdminMountsFor($type, $value) {
$builder = $this->connection->getQueryBuilder();
* @param int $type any of the self::APPLICABLE_TYPE_ constants
* @param string[] $values user_ids or group_ids
* @return array
- * @suppress SqlInjectionChecker
*/
public function getAdminMountsForMultiple($type, array $values) {
$builder = $this->connection->getQueryBuilder();
* @param int $type any of the self::APPLICABLE_TYPE_ constants
* @param string|null $value user_id, group_id or null for global mounts
* @return array
- * @suppress SqlInjectionChecker
*/
public function getUserMountsFor($type, $value) {
$builder = $this->connection->getQueryBuilder();
* @param Table $table
* @param InputInterface $input
* @param OutputInterface $output
- * @suppress SqlInjectionChecker
*/
protected function copyTable(Connection $fromDB, Connection $toDB, Table $table, InputInterface $input, OutputInterface $output) {
if ($table->getName() === $toDB->getPrefix() . 'migrations') {
* @param IOutput $output
* @param \Closure $schemaClosure The `\Closure` returns a `ISchemaWrapper`
* @param array $options
- *
- * @suppress SqlInjectionChecker
*/
public function postSchemaChange(IOutput $output, \Closure $schemaClosure, array $options) {
$qb = $this->connection->getQueryBuilder();
* get the next job in the list
*
* @return IJob|null
- * @suppress SqlInjectionChecker
*/
public function getNext() {
$query = $this->connection->getQueryBuilder();
* Remove the reservation for a job
*
* @param IJob $job
- * @suppress SqlInjectionChecker
*/
public function unlockJob(IJob $job) {
$query = $this->connection->getQueryBuilder();
* @param int $folderId
* @param IUser $user
* @return array [$fileId => $unreadCount]
- *
- * @suppress SqlInjectionChecker
*/
public function getNumberOfUnreadCommentsForFolder($folderId, IUser $user) {
$qb = $this->dbConn->getQueryBuilder();
* @param \DateTime $dateTime
* @param IUser $user
* @since 9.0.0
- * @suppress SqlInjectionChecker
*/
public function setReadMark($objectType, $objectId, \DateTime $dateTime, IUser $user) {
$this->checkRoleParameters('Object', $objectType, $objectId);
}
}
- /**
- * @suppress SqlInjectionChecker
- */
public function insertIgnoreConflict(string $table,array $values) : int {
try {
$builder = $this->conn->getQueryBuilder();
return $statement;
}
- /**
- * @suppress SqlInjectionChecker
- */
public function insertIgnoreConflict(string $table,array $values) : int {
if ($this->isPre9_5CompatMode() === true) {
return parent::insertIgnoreConflict($table, $values);
* @return int number of new rows
* @throws \Doctrine\DBAL\DBALException
* @throws PreConditionNotMetException
- * @suppress SqlInjectionChecker
*/
public function setValues($table, array $keys, array $values, array $updatePreconditionValues = []) {
try {
*
* @return int file id
* @throws \RuntimeException
- *
- * @suppress SqlInjectionChecker
*/
public function insert($file, array $data) {
// normalize file
* @param string $targetPath
* @throws \OC\DatabaseException
* @throws \Exception if the given storages have an invalid id
- * @suppress SqlInjectionChecker
*/
public function moveFromCache(ICache $sourceCache, $sourcePath, $targetPath) {
if ($sourceCache instanceof Cache) {
* @param string $internalPath
* @param int $time
* @param int $sizeDifference number of bytes the file has grown
- * @suppress SqlInjectionChecker
*/
public function propagateChange($internalPath, $time, $sizeDifference = 0) {
// Do not propogate changes in ignored paths
/**
* Commit the active propagation batch
- * @suppress SqlInjectionChecker
*/
public function commitBatch() {
if (!$this->inBatch) {
/**
* @param array $users
* @return array
- * @suppress SqlInjectionChecker
*/
public function getUsedSpaceForUsers(array $users) {
$builder = $this->connection->getQueryBuilder();
/**
* @param string $path
* @param int $type self::LOCK_SHARED or self::LOCK_EXCLUSIVE
- *
- * @suppress SqlInjectionChecker
*/
public function releaseLock(string $path, int $type) {
$this->markRelease($path, $type);
/**
* release all lock acquired by this instance which were marked using the mark* methods
- *
- * @suppress SqlInjectionChecker
*/
public function releaseAll() {
parent::releaseAll();
* @param string $sourceId
* @param string $sourceNullColumn If this column is null in the source table,
* the entry is deleted in the $deleteTable
- * @suppress SqlInjectionChecker
*/
protected function deleteOrphanEntries(IOutput $output, $repairInfo, $deleteTable, $deleteId, $sourceTable, $sourceId, $sourceNullColumn) {
$qb = $this->connection->getQueryBuilder();
* Must throw exception on error.
*
* @throws \Exception in case of failure
- * @suppress SqlInjectionChecker
*/
public function run(IOutput $output) {
$deletedEntries = 0;
/**
* Adjust file share permissions
- * @suppress SqlInjectionChecker
*/
private function adjustFileSharePermissions(IOutput $out) {
$mask = \OCP\Constants::PERMISSION_READ | \OCP\Constants::PERMISSION_UPDATE | \OCP\Constants::PERMISSION_SHARE;
* @param string $action
* @param string $ip
* @param array $metadata Optional metadata logged to the database
- * @suppress SqlInjectionChecker
*/
public function registerAttempt(string $action,
string $ip,
/**
* @param string $username
* @throws \OC\DatabaseSetupException
- * @suppress SqlInjectionChecker
*/
public function setupDatabase($username) {
try {
* @param Entity $entity the entity that should be created
* @return Entity the saved entity with the set id
* @since 14.0.0
- * @suppress SqlInjectionChecker
*/
public function insert(Entity $entity): Entity {
// get updated fields to save, fields have to be set using a setter to
* @return Entity the saved entity with the (new) id
* @throws \InvalidArgumentException if entity has no id
* @since 15.0.0
- * @suppress SqlInjectionChecker
*/
public function insertOrUpdate(Entity $entity): Entity {
try {
* @param Entity $entity the entity that should be created
* @return Entity the saved entity with the set id
* @since 14.0.0
- * @suppress SqlInjectionChecker
*/
public function update(Entity $entity): Entity {
// if entity wasn't changed it makes no sense to run a db query