sharepoint online – Adding newly create group to “Site Permissions” section ( XXX/_layouts/15/user.aspx )

After creating a SharePoint group, you need to assign the permissions to it at site (web) level.

Add a new action ‘Send HTTP request to SharePoint’ and configure the action to use endpoint as below:

/_api/web/roleassignments/addroleassignment(principalid=<GROUPID>, roledefid=1073741827)

roledefid is for Permission Levels which are as follows:

1073741829 – Full Control

073741827 – Contribute

1073741826 – Read

<GroupID> is the id of the group.

Reference: SharePoint Group Operations in Microsoft Flow

power automate – Adding newly create site to “Site Permissions” section ( XXX/_layouts/15/user.aspx )

Hope you are all doing well.

I managed to use Power Automate to create SP groups and add users to them using the HTTP request action.

The problem i have is the newly created groups are created at the “root” (in People and Groups section) level but not in the site in the “Site Permissions” section so user that i add to the group still do not have access to the site.

I created a flow that adds the group(s) to “site Pages” , “Site assets” and to the specific libraries but they don’t have access to the site itself since the groups are not in “Site Permissions”.

Does anyone know how to add a newly created group to “Site Permissions” ?

Thanks a lot in advance !!

SQL Server Agent & sp_send_dbmail failing on permissions

I have set up an SQL Server Agent job to call sp_send_dbmail with a very simple select on a certain table in a certain database. Within the properties->permissions of the target database the Database Role ‘public’ has ‘select’ permission. The job runs fine, the email arrives, all good.

The problem is, if I turn off the worryingly generous ‘public’ select permission and try to add the SQLServerAgent user (which is the user the agent is running under and the user that owns the agent job) and give them select permissions, the job fails.

Can anyone shed any light on this for me? I suspect that maybe a different user is involved in some way. I cannot get SQL Server Profiler to run (it’s not installed) and I don’t have access to the server to install it.

Thanks
C

Permissions issue when starting openvpn-server with systemd

Just installed openvpn on my VPS.

Starts flawlessly with

sudo openvpn /etc/openvpn/server/server.conf

But

sudo systemctl start openvpn-server@server

won’t run. There’s a conflict with systemd.

The logs:

Options error: --ca fails with '/etc/openvpn/server/ca.crt': Permission denied (errno=13)
Options error: --cert fails with '/etc/openvpn/server/server.crt': Permission denied (errno=13)
Options error: --key fails with '/etc/openvpn/server/server.key': Permission denied (errno=13)
Options error: Please correct these errors.

My server folder with keys and certificates:

ls -la
total 36
drwxr-x--- 2 openvpn network 4096 Jan 11 00:24 .
drwxr-xr-x 5 root    root    4096 Jan 11 00:02 ..
-rw------- 1 root    root    1184 Jan 10 23:26 ca.crt
-rw-r--r-- 1 root    root     424 Jan 10 23:29 dh2048.pem
-rw-r--r-- 1 root    root     618 Jan 11 16:07 server.conf
-rw------- 1 root    root    4586 Jan 10 23:28 server.crt
-rw------- 1 root    root    1704 Jan 10 23:27 server.key
-rw------- 1 root    root     636 Jan 10 23:43 ta.key

Can you spot a mistake in permissions?

files – Setting folder permissions on Cloudways

I recently changed to Cloudways where I have a server on Digital Ocean running Debian. I am about to roll out a Drupal installation into production, but cant get the file- and folder-permission to pass the automated security review (module) test.

My permissions look like this:

drwxr-xr-x  11 ggmpyecgmg www-data     4096 Jän  7 21:58 .
drwxr-xr-x+  9 root       ggmpyecgmg   4096 Jän 10 15:11 ..
-rw-r--r--   1 ggmpyecgmg www-data      312 Jän  7 02:54 autoload.php
-rw-r--r--   1 ggmpyecgmg www-data     3156 Jän  7 02:54 composer.json
-rw-r--r--   1 ggmpyecgmg www-data   165592 Jän  7 02:54 composer.lock
drwxr-xr-x  12 ggmpyecgmg www-data     4096 Jän  7 02:54 core
-rw-r--r--   1 ggmpyecgmg www-data     1025 Jän  7 02:54 .csslintrc
-rw-r--r--   1 ggmpyecgmg www-data      357 Jän  7 02:54 .editorconfig
-rw-r--r--   1 ggmpyecgmg www-data      151 Jän  7 02:54 .eslintignore
-rw-r--r--   1 ggmpyecgmg www-data       41 Jän  7 02:54 .eslintrc.json
-rw-r--r--   1 ggmpyecgmg www-data     1507 Jän  7 02:54 example.gitignore
drwxr-xr-x  12 ggmpyecgmg www-data     4096 Jän 10 16:19 files
-rw-r--r--   1 ggmpyecgmg www-data     3858 Jän  7 02:54 .gitattributes
-rw-r--r--   1 ggmpyecgmg www-data     7572 Jän  7 19:13 .htaccess
-rw-r--r--   1 ggmpyecgmg www-data     2314 Jän  7 02:54 .ht.router.php
-rw-r--r--   1 ggmpyecgmg www-data      549 Jän  7 02:54 index.php
drwxr-xr-x   5 ggmpyecgmg www-data     4096 Dez 23 07:38 libraries
drwxr-xr-x  49 ggmpyecgmg www-data     4096 Jän 10 16:18 modules
drwxr-xr-x   2 ggmpyecgmg www-data     4096 Dez  2 18:21 profiles
-rw-r--r--   1 ggmpyecgmg www-data     1586 Jän  7 19:13 robots.txt
drwxr-xr-x   3 ggmpyecgmg www-data     4096 Dez 30 20:41 sites
drwxr-xr-x   3 ggmpyecgmg www-data     4096 Dez 30 20:36 themes
drwxr-xr-x   6 ggmpyecgmg www-data     4096 Jän 10 16:18 tmp
-rw-r--r--   1 ggmpyecgmg www-data      804 Jän  7 02:54 update.php
drwxr-xr-x  19 ggmpyecgmg www-data     4096 Jän  7 02:54 vendor
-rw-r--r--   1 ggmpyecgmg www-data     4566 Jän  7 02:54 web.config

In my understanding, www-data should not have any write permissions by now. But still, security review module promts: “The following files and directories appear to be writeable by your web server.” And then followed by a huge list of files in /modules, /core, /vendor and so on…

I changed ownership “chown -R ggmpyecgmg:www-data /drupal_root_folder”
Then I took away writing permission of www-data by “chmod -R g-w” for the root folder.

But still, everything seems to be writeable for apache.

Has anybody experience with setting up file permissions on Cloudways / Digital Ocean? Can anybody point me anything I might have overlooked?

I am a litte desperated already. Thank you very much in advance!

files – Setting folder permissions for Drupal on Cloudways

I recently changed to Cloudways where I have a server on Digital Ocean running Debian. I am about to roll out a Drupal installation into production, but cant get the file- and folder-permission to pass the automated security review (module) test.

My permissions look like this:

drwxr-xr-x  11 ggmpyecgmg www-data     4096 Jän  7 21:58 .
drwxr-xr-x+  9 root       ggmpyecgmg   4096 Jän 10 15:11 ..
-rw-r--r--   1 ggmpyecgmg www-data      312 Jän  7 02:54 autoload.php
-rw-r--r--   1 ggmpyecgmg www-data     3156 Jän  7 02:54 composer.json
-rw-r--r--   1 ggmpyecgmg www-data   165592 Jän  7 02:54 composer.lock
drwxr-xr-x  12 ggmpyecgmg www-data     4096 Jän  7 02:54 core
-rw-r--r--   1 ggmpyecgmg www-data     1025 Jän  7 02:54 .csslintrc
-rw-r--r--   1 ggmpyecgmg www-data      357 Jän  7 02:54 .editorconfig
-rw-r--r--   1 ggmpyecgmg www-data      151 Jän  7 02:54 .eslintignore
-rw-r--r--   1 ggmpyecgmg www-data       41 Jän  7 02:54 .eslintrc.json
-rw-r--r--   1 ggmpyecgmg www-data     1507 Jän  7 02:54 example.gitignore
drwxr-xr-x  12 ggmpyecgmg www-data     4096 Jän 10 16:19 files
-rw-r--r--   1 ggmpyecgmg www-data     3858 Jän  7 02:54 .gitattributes
-rw-r--r--   1 ggmpyecgmg www-data     7572 Jän  7 19:13 .htaccess
-rw-r--r--   1 ggmpyecgmg www-data     2314 Jän  7 02:54 .ht.router.php
-rw-r--r--   1 ggmpyecgmg www-data      549 Jän  7 02:54 index.php
drwxr-xr-x   5 ggmpyecgmg www-data     4096 Dez 23 07:38 libraries
drwxr-xr-x  49 ggmpyecgmg www-data     4096 Jän 10 16:18 modules
drwxr-xr-x   2 ggmpyecgmg www-data     4096 Dez  2 18:21 profiles
-rw-r--r--   1 ggmpyecgmg www-data     1586 Jän  7 19:13 robots.txt
drwxr-xr-x   3 ggmpyecgmg www-data     4096 Dez 30 20:41 sites
drwxr-xr-x   3 ggmpyecgmg www-data     4096 Dez 30 20:36 themes
drwxr-xr-x   6 ggmpyecgmg www-data     4096 Jän 10 16:18 tmp
-rw-r--r--   1 ggmpyecgmg www-data      804 Jän  7 02:54 update.php
drwxr-xr-x  19 ggmpyecgmg www-data     4096 Jän  7 02:54 vendor
-rw-r--r--   1 ggmpyecgmg www-data     4566 Jän  7 02:54 web.config

In my understanding, www-data should not have any write permissions by now. But still, security review module promts: “The following files and directories appear to be writeable by your web server.” And then followed by a huge list of files in /modules, /core, /vendor and so on…

I changed ownership “chown -R ggmpyecgmg:www-data /drupal_root_folder”
Then I took away writing permission of www-data by “chmod -R g-w” for the root folder.

But still, everything seems to be writeable for apache.

Has anybody experience with setting up file permissions on Cloudways / Digital Ocean? Can anybody point me anything I might have overlooked?

I am a litte desperated already. Thank you very much in advance!

SharePoint 2013 Workflow – App Permissions using java script

I have created a SharePoint 2013 workflow and using App Step in the workflow, I have saved the site as a template and created a new site using the JavaScript object model. The SharePoint 2013 workflow App Step was not working fine until I manually enable the App Step trust in the newly created site.

I am creating the site from site template using JavaScript object model and someone help in enabling the App Step trust using the JavaScript object model.

9 – How can I get the list of user permissions through rest API?

This function will return the permissions that have been assigned to a specific user :

use  DrupaluserEntityUser;

function getUserPermissions(User $user) {

$user_roles = $user->getRoles();
$roles_permissions = user_role_permissions($user_roles);

$permissions_array = array();
foreach ($roles_permissions as $role_key => $permissions) {
  foreach ($permissions as $permission) {
    $array() = $permission;
  }

return $permissionsarray;
}


to get the permissions of any user just use the user id ex:

$user = DrupaluserEntityUser::load(123);
$user_permissions = getUserPermissions($user);

Or to get permissions of current user just use:

$user = Drupal::currentUser();
$current_user_permissions =getUserPermissions($user);

Then just inject the result into the RestResource response:

   $response = (
       'current_user_permissons' => $current_user_permissions
     );
   return new ResourceResponse($response);

permissions – Unable to delete folders or files in SharePoint site linked to a Team

I am unable to delete folders or documents in a SharePoint library that is linked to a particular MS Team. When I click on the ellipses of a folder or file the delete option is not there (it is there for other SharePoint/teams libraries).

I have checked to see if there are any files checked out and there are none.

I have managed to delete the folder by going into Classic SharePoint view and the deleting via the files tab. But I am just confused as to why I couldn’t delete them in the normal way. I have checked the settings for the site and can’t see anything out of the ordinary.

Any help would be appreciated!

file permissions – Termux (specifically npm) can’t install in internal storage

Everytime I try to use NPM to install something into /storage/emulated/0/dir it would always do this:

npm WARN tar EPERM: operation not permitted, futime
npm WARN tar EPERM: operation not permitted, futime
npm WARN tar EPERM: operation not permitted, futime
npm WARN tar EPERM: operation not permitted, futime
npm WARN tar EPERM: operation not permitted, futime
npm WARN tar EPERM: operation not permitted, futime
npm WARN tar EPERM: operation not permitted, futime
npm WARN tar EPERM: operation not permitted, futime
npm WARN tar EPERM: operation not permitted, futime
npm WARN tar EPERM: operation not permitted, futime
npm WARN tar EPERM: operation not permitted, futime

It has access to download things using git and other methods but it never seems to work using NPM.