permissions

How to request permissions during run time when using Gluon mobile environment?

安稳与你 提交于 2019-12-07 22:50:08
问题 I am new here and reason for that I don't know all rules of the site yet, sorry about that! I am building a Java application to Desktop and Android by using Gluon mobile plugin in Eclipse tool. I have variated code for Desktop and Android as described in an example (http://docs.gluonhq.com/samples/gonative/). So I have Android specific NativeService where I have a method to read files from external storage (that works). I have also studied how to request permissions on run time when using

preserving file permission when creating a tarball with Python's tarfile

故事扮演 提交于 2019-12-07 21:57:01
问题 hello stackoverflowers, I want to preserve the original file permissions when using Python's tarfile module. I have quite a few executable files that lose their permissions once the tarball is extracted. I'm doing something like this: import tarfile tar = tarfile.open("mytarball.tar.gz", 'w:gz') tar.add('my_folder') #tar the entire folder tar.close() Then I copy it from windows to a linux machine (mapped with samba) using shutil: shutil.copy("mytarball.tar.gz",unix_dir) Then, to extract the

Can't access apache web apps locally using IP or PC Name

老子叫甜甜 提交于 2019-12-07 21:18:34
问题 I installed Wamp Server on Windows 8. I then installed a php web application. I can access it by going http:// localhost/webapp or http:// localhost/phpmyadmin I want to be able to access this web app from different computers on the same network. The problem is when I try to visit my web app via this http:// 192.168.133.221/webapp (which is my local ip address) or http:// mypc/webapp (which is my PC's name) - I get the following error 403 Forbidden You don't have permission to access

Dynamically pick the user GUI and UID who's running Docker at the host from entrypoint

风格不统一 提交于 2019-12-07 21:14:04
问题 I have the following script as the ENTRYPOINT of my Dockerfile and therefore Docker image: #!/bin/bash set -e # Setup permissions data_dir="/var/www/html" usermod -u 1000 www-data && groupmod -g 1000 www-data chown -R www-data:root "$data_dir" if [ -d "$data_dir" ]; then chgrp -R www-data "$data_dir" chmod -R g+w "$data_dir" find "$data_dir" -type d -exec chmod 2775 {} + find "$data_dir" -type f -exec chmod ug+rw {} + fi # Enable rewrite a2enmod rewrite expires # Apache gets grumpy about PID

Acquire “signature” permissionlevel on Android

隐身守侯 提交于 2019-12-07 21:01:49
问题 I'm building an Android app, and one of the permission I need is defined as: android:protectionLevel="signature|system|development" How do I get the signature protection level? Do I need to sign my application somehow? Do I need to sign it with OEM ? (Samsung\HTC\LG)? 回答1: signature means that to be able to get access to the resource, your app have to be signed with the same certificate that the holder of the permission. If this is not your app you are trying to connect to, then you basically

Get path from FileDescriptor in Java

邮差的信 提交于 2019-12-07 20:08:39
问题 Some quick background on my problem: I'm writing a compiler that converts Domain Type Enforcement specs into Java Security Manager code. In a nutshell, DTE defines "types" (objects), assigns paths to those types; then defines "domains" (subjects), and defines what permissions (rwxdc) domains have to various types. I need to emulate this behavior as closely as possible in the JSM. Currently I'm working on write permissions. I've overridden the JSM's checkWrite(String filename) method

Get Location Permissions from User in Android Application [duplicate]

自古美人都是妖i 提交于 2019-12-07 18:23:33
问题 This question already has answers here : How to request Location Permission at runtime (5 answers) Closed 2 years ago . I´m trying to get the users actual location with the typicaly permissions box: like this: If anyone knows how to make it , pleas answer. 回答1: Ask for permission at runtime to use device current location as below : if (ActivityCompat.checkSelfPermission(YourActivity.this, Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED && ActivityCompat

Permissions required for 'CREATE USER' in SQL Server 2005?

こ雲淡風輕ζ 提交于 2019-12-07 18:06:49
问题 I am trying to create a SQL server login and database user from within my application, along with a custom application user row. I want these users to be able to create other users - i.e. the application will control who can/can't create users but I need all users to have permissions for creating SQL server logins and database users. I have got the server login permissions working - i.e. an existing user/login can create a new login - by adding the logins to the 'securityadmin' server role -

Changing owner of HKCR\CLSID\* key to Administrator on Windows Server 2008 R2

爱⌒轻易说出口 提交于 2019-12-07 17:53:55
问题 There is a registry key on Win Server 2008 R2, HKCR:\CLSID\{76A64158-CB41-11D1-8B02-00600806D9B6} whose owner is not Administrator. It is TrustedInstaller. Now to make Remote DCOM/WMI connection working, I need to give Administrator the permission to have Full Control over this key and ownership as well. As this needs to be done on several machines, I was hoping I could do this using Powershell. I followed these Controlling Registry ACL Permissions with Powershell Change the owner of

SSIS package not running when called as step in SQL Job

醉酒当歌 提交于 2019-12-07 17:47:07
问题 I have a .dtsx file (an SSIS package) that downloads files from an FTP server and imports data. It runs fine whenever I run it manually. However, when I schedule calling the package as a step in a SQL server agent job, it fails. The step it fails at is the one where I call a .bat file. The error in the job history viewer says this: Error: 2009-05-26 12:52:25.64 Code: 0xC0029151 Source: Execute batch file Execute Process Task Description: In Executing "D:\xxx\import.bat" "" at "", The process