permissions

can't load_file data in the mysql directory

删除回忆录丶 提交于 2019-12-11 14:22:38
问题 I'm running as mysql root user on my system. I can select load_file('/etc/passwd'); no problem But when I try to select load_file('/var/lib/mysql/mysql'); I get NULL as a result why? this file is good, I can cat it as root and view the mysql user data, why cant mysql load_file it? Its permissions are the default: -rw-rw---- 1 mysql mysql 444 2009-08-04 19:08 user.MYD It's owner is by default the user mysql and has read permission, so why doesn't mysql like to load_file it? Is mysql somehow

WordPress can't install themes

南笙酒味 提交于 2019-12-11 14:09:42
问题 I can't workout how to solve this problem so wordpress would let me upload themes. I have a fresh copy of Fedora 17 installed on my dev machine. I then installed mysql using: yum install mysql mysql-server . Next I installed WordPress which also installs apache and php: yum install wordpress I can go to http://localhost/wordpress and see WordPress working. But when I try tried to install my theme it asked for ftp credentials. I then updated the wp-config.php file and set the FS_METHOD

How i can request permission at runtime in Android?

心已入冬 提交于 2019-12-11 13:56:29
问题 I'm developing an Android application, I have to allow users to use camera to scan a QRCode. In each Android version (except > 6.0) i haven't problem, but in marshmallow I must enable manually the permission from "Settings -> App ->Permission" (it's strange because I have declared the camera permission in the manifest). I read the documentation dev-android website but i don't understand some things: if (ContextCompat.checkSelfPermission(thisActivity, Manifest.permission.READ_CONTACTS) !=

Security Manager in Clojure

不羁的心 提交于 2019-12-11 13:54:29
问题 I try to install a security manager from a Clojure program and am stuck short after a good start. This one works for me in Clojures simple REPL , in the Lein REPL, and in the Cider REPL in Emacs. It prevents the use of ( System/exit n ). (def SM (proxy [SecurityManager] [] (checkPermission [^java.security.Permission p] (when (.startsWith (.getName p) "exitVM") (throw (SecurityException. "exit")))))) (System/setSecurityManager SM) But I want to do this security manager to do more. E.g. log any

Best place to store the trial data for the web application

自作多情 提交于 2019-12-11 13:34:25
问题 After reading a lot of SO topics about how to design a trial for the desktop software I still have some questions about trial for Web Application. I have a ASP.Net MVC Web Application and I'm offering a time limited trial for that. The applicaion will run in IIS > 7.0 so it has a very limited acces to the system and that is why there are not a lot of places for storing the information about the remaining trial. I'm not trying to make my software "uncrackable", but it shouldn't be obvious for

Object permissions with read only access for anonymous users in Django Rest Framework

廉价感情. 提交于 2019-12-11 13:26:14
问题 The problem I am using Django REST Framework - and so far I have been using the DjangoObjectPermissions permissions class. I use django-rules to determine which users have permissions for objects. However, this permissions class seems to deny read access to anonymous users. I need to find the best way to allow read-only access to all users (authenticated or not). For additions, modifications and deletions - the object permissions should be applied as normal. What is the best approach to

signatureOrSystem permissions on custom ROM

喜夏-厌秋 提交于 2019-12-11 13:09:09
问题 I'm wondering about how is a signatureOrSystem permissions enforced on custom ROMs. Docs say: A permission that the system grants only to applications that are in the Android system image or that are signed with the same certificates as those in the system image. Where is this certificate? In case I'm using a custom ROM, say CyanogenMod, can I obtain their certificate, which I'm assuming is freely available, and sign my application so that it could use such a permission (only with that ROM of

File.Exists() incorrectly returning false from ASP.NET - security issue related to Thread vs Process identity?

限于喜欢 提交于 2019-12-11 12:13:44
问题 I have an ASP.NET app using Windows authentication, and I'm testing for the existence of a file on a remote server. I'm authenticating as MYDOMAIN\my.username - this works. The file is \MYSERVER\WebShare\example.txt. This file exists. I can open it from various hosts whilst logged in as MYDOMAIN\my.username. Under Windows Explorer, the effective permissions indicate that MYDOMAIN\my.username has full control of this file. If I attach a debugger and type $user in the watch window, I can see

Detect when asked and granted permission to iOS notifications?

纵然是瞬间 提交于 2019-12-11 12:12:43
问题 In the iOS client when you first run it you get a UIAlert asking for permission to grant access to send this person notifications. I'm wondering if its possible to first: Catch when this alert will fire (before it happens) Catch what response is given (cancel or ok) (after it happens) Is there such a way to get callbacks for the above two scenarios? Many thanks 回答1: On iOS 8 and later, implement the following method in your AppDelegate: - (void)application:(UIApplication *)application

How can I add a non-model/queryset returning view with django-restframework when using DjangoObjectPermissions?

扶醉桌前 提交于 2019-12-11 12:03:54
问题 I have a view that I want to add to my django-restframework api that does not relate to any model. Though I'm using 'rest_framework.permissions.DjangoObjectPermissions' in DEFAULT_PERMISSION_CLASSES. class EnumChoices(views.APIView): def get(self, request): enums = {} return Response(enums) Now Django complains about my view: AssertionError at /api/enums/ Cannot apply DjangoModelPermissions on a view that does not have `.queryset` property or overrides the `.get_queryset()` method. I need the