Android应用程序在使用很多功能的时候必须在Mainifest.xml中声明所需的权限,否则无法运行。下面是一个Mainifest.xml文件的例子:

<?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android"       package="hi.braincol.local.filebrowser"       android:versionCode="1"       android:versionName="1.0.0">     <application android:icon="@drawable/icon" android:label="@string/app_name">         <activity android:name=".FileBrowser"                   android:label="@string/app_name">             <intent-filter>                 <action android:name="android.intent.action.MAIN" />                 <category android:name="android.intent.category.LAUNCHER" />             </intent-filter>         </activity>     </application>    <uses-permission android:name="android.permission.ACCESS_SURFACE_FLINGER"/>    <uses-permission android:name="android.permission.VIBRATE"/> </manifest>

上面xml文件中的:
就是允许应用程序使用SurfaceFlinger的底层属性。

Android中为应用程序准备了很多可选权限,下面是Android应用程序权限清单:

android.permission.ACCESS_CHECKIN_PROPERTIES:
Allowsread/writeaccesstothe“properties”tableinthecheckindatabase,tochangevaluesthatgetuploaded.
允许以read/write访问检入数据库(checkindatabase?)的”properties”表,并且可以更改、更新数据库。

android.permission.ACCESS_COARSE_LOCATION:
Allowsanapplicationtoaccesscoarse(e.g,Cell-ID,WiFi)location.
允许一个应用程序通过访问CellIDWiFi热点等方式获取粗略的本地位置。

android.permission.ACCESS_FINE_LOCATION:
Allowsanapplicationtoaccessfine(e.g,GPS)location.
允许一个应用程序通过访问GPS等方式获取较精确的本地位置。

android.permission.ACCESS_LOCATION_EXTRA_COMMANDS:
Allowsanapplicationtoaccessextralocationprovidercommands.
允许一个应用程序访问(使用)额外的本地位置服务提供者。

android.permission.ACCESS_MOCK_LOCATION:
Allowsanapplicationtoaccessmocklocationprovidersfortesting.
允许一个应用程序访问(创建)模拟的位置服务提供者用于测试。

android.permission.ACCESS_NETWORK_STATE:
Allowsapplicationstoaccessinformationaboutnetworks.
允许应用程序访问(获取)网络信息。

android.permission.ACCESS_SURFACE_FLINGER:
AllowsanapplicationtouseSurfaceFlinger’slowlevelfeatures.
允许一个应用程序使用SurfaceFlinger的底层属性。(什么是SurfaceFlinger?

android.permission.ACCESS_WIFI_STATE:
AllowsapplicationstoaccessinformationaboutWi-Finetworks.
允许应用程序获取Wi-Fi网络的信息)。

android.permission.ACCOUNT_MANAGER:
AllowsanapplicationstocallintoAccountAuthenticators.
允许一个应用程序启动账户认证。

android.permission.AUTHERTICATE_ACCOUTS:
AllowsanapplicatonstoactasanAccoutAuterticatorfortheAccoutManger.
允许一个应用程序充当账户认证管理者。

android.permission.BATTERY_STATS:

Allowsanapplicationtocollectbatterystatistics.

允许一个应用程序获取电池使用的统计信息(剩余电量、电池的耗电情况(各主要应用程序耗电占总耗电的百分比等)等)

android.permission.BIND_APPWIGET:

AllowsanapplicationtotelltheAppWigetservicewhichapplicationcanaccessAppWigetdata.

允许一个应用程序告知AppWiget服务:我(当前应用程序)可以访问AppWiget数据。

android.permission.BIND_DEVICE_ADMIN:

Mustberequiredbydeviceadministrationreceiver,toensurethatonlythesystemcaninteractwithit.

设备管理服务必须拥有的权限,确保只有系统可以通过设备管理服务与设备进行互动(访问设备,数据交互)。

android.permission.BIND_INPUT_METHOD:

MustberequiredbyanInputMethodService,toensurethatonlythesystemcanbindtoit.

输入法服务(InputMethodService)必须拥有的权限,确保只有系统可以绑定之。

android.permission.BIND_WALLPAPER:
MustberequiredbyaWallpaperService,toensurethatonlythesystemcanbindtoit.

桌面服务(WallpaperService)必须拥有的权限,确保只有系统才可以绑定之.

android.permission.BLUETOOTH:

Allowsapplicationstoconnecttopairedbuletoothdevices.

允许应用程序连接到已配对的蓝牙设备(远端蓝牙,非本机蓝牙)。

android.permission.BULETOOTH_ADMIN:
Allowsapplicationstodiscoveranpairbluetoothdevices.

允许应用程序搜索并且配对蓝牙设备。

android.permission.BRICK:

Requiredtobeabletodisablethedevice(verydangrous!).

禁用设备必须拥有的权限(危险,慎用!)。

android.permission.BROADCAST_PACKAGE_REMOVED:

Allowsanapplicationtoboradcastanotificationthatanapplicationpackagehasbeenremoved.

允许一个应用程序广播一个(不是同一个)应用程序包已经被移除的通告。(指一个应用程序已被卸装的通告?)

android.permission.BROADCAST_SMS:
AllowsanapplicationtobroadcastanSMSreceiptnotification.

允许一个应用程序广播一个短信回执(如:帅哥,你有一条新的短消息!)的通告。

android.permission.BROADCAST_STICKY:

Allowsanapplicationtobroadcaststickyintents.

允许一个应用程序广播常用(sticky?)intents.

android.permission.WAP_PUSH:

AllowsanapplicationtobroadcastaWAPPUSHreceiptnotification.

允许一个应用程序广播WAPPUSH回执通告。

说明:WAP-PUSHWAP推送短信,是一种特殊格式的短信。WAP-PUSH可以将某一站点或某一业务的链接通过短息发送到支持WAP的设备,WAPPUSH实现了短信和WAP业务的结合。

android.permission.CALL_PHONE:
AllowsanapplicationtoinitiateaphonecallwithoutgoingthroughtheDialeruserinterfacefortheusertoconfirmthecallbeingplaced.

允许应用程序不经过用户拨号界面而直接拨号。

android.permission.CALL_PRIVILEGED:

Allowsanapplicationtocallanyphonenumber,includingemergencynumbers,withoutgoingthrougththeDialeruserinterfaceforconfirmthecallbeingpalced.

允许应用程序不经过用户拨号界面而拨打任意号码(包括紧急号码)。(紧急号码是指哪些?)

android.permission.CAMERA:

Requiredtobeabletoaccessthecameradevice.

访问摄像头设备必须具备的权限。

android.permission.CHANGE_COMPONENT_ENABLED_STATE:
Allowsanapplicationtochangewhetheranapplicationcomponent(otherthanitsown)isenabledornot.

允许一个应用程序改变另一个应用程序组件的启用状态(禁用或启用)。

android.permission.CHANGE_NETWORK_STATE:

Allowsapplicationstochangenetworkconnecititystate.

允许应用程序更改网络连接状态。

android.permission.CHANGE_WIFIMULTICAST_STATE:

AllowsapplicationstoenterWi-FiMulticastmode.

允许应用程序进入Wi-FiMulticast模式。

说明:Multicast,多重广播,网络中的一个节点发出的信息被多个节点接收。

android.permission.CHANGE_WIFI_STATE:

AllowsapplicationstochangeWi-Ficonnectivitystate.

允许应用程序更改Wi-Fi连接状态。

android.permission.CLEAR_APP_CACHE:

Allowsanapplicationtoclearthecachesofallinstalledapplicationonthedevice.

允许一个应用程序清理所有已安装程序的设备缓冲区(是安装的时候使用的缓冲区,还是运行时候的缓冲区?)

android.permission.CLEAR_APP_USER_DATA:
Allowsanapplicationtoclearuserdata.

允许一个应用程序清理用户数据。

android.perimmision.CONTROL_LOCATION_UPDATES:

Allowsenabling/disablinglocationupdatenotificationfromtheradio.

允许启用/禁用位置更新的提示信息。(fromtheradio?通过电波获得的位置更新信息?)

android.permission.DELETE_CACHE_FILES:

Allowsanapplicationtodeletecachefiles.

允许一个应用程序删除cache文件。

android.permission.DLEETE.PACKAGES:

Allowsanapplicationtodeletepackages.

允许一个应用程序删除packagesapk安装包?还是所有类型的压缩包?)

android.permission.DEVICE_POWER:

Allowslow-levelaccesstopowermanagement.

允许访问底层的电源管理。

android.permission.DIAGNOSTIC:

AllowsapplicationtoRWtodiagnosticresources.

允许应用程序读写诊断资源(diagnosticresources)。(什么事diagnosticresources?诊断信息,log?)

android.permission.DISABLE_KEYGUARD:

Allowsaplicationstodisablethekeyguard.

允许应程序禁用键盘锁。

android.permission.DUMP:

Allowsanapplicationtoretrievestatedumpinformationfromsystemservices.

允许一个应用程序从系统服务中抓取(检索)状态转储信息。(什么是statedump?将数据从一个设备转存到另外一个设备?)

android.permission.EXPAND_STATUS_BAR:

Allowsanapplicatontoexpandorcollapsethestatusbar.

允许一个应用程序扩张或收缩状态栏。

android.permission.FACTORY_TEST:

Runasanmanufacturertestapplication,runningastherootuser.

允许像厂家测试程序那样以root用户权限运行应用程序。

android.permission.FLSHLIGHT:

Allowsaccesstotheflashlight.

允许访问闪光信号灯。

android.permission.FORCE_BACK:

AllowsanapplicationtoforceaBACKoperationonwhateveristhetopactivity.

允许一个应用程序在activity上强制执行一个回退操作,无论这个activity是否是顶层的activity

android.permission.GET_ACCOUNTS:

AllowsaccesstothelistofaccoutsintheAccountsService.

允许访问账号服务的账号列表。

android.permission.GET_PACKAGE_SIZE:

Allowsanapplicationtofindoutthespaceusedbyanypackage.

允许应用程序获得任何package占用的存储空间。

android.permission.GET_TASKS:

Allowsanappllicationtogetinformationaboutthecurrentlyorrecentlyrunningtasks:athumbnailrepresentationofthetasks,whatactivitiesarerunninginit,etc.

允许一个应用程序获得的当前或最近运行的任务信息:像在任务中运行了哪些activitys等一些简短信息。

android.permission.GLBOAL_SEARCH:

Thispermissioncanbeusedoncontentproviderstoallowtheglobalsearchsystemtoaccesstheirdata.

拥有该权限的contentproviders将允许全局搜索系统访问其数据。

android.permission.HARDWARE_TEST:

Allowsaccesstohardwareperipherals.

允许访问外设。

android.permission.INJECT_EVENTS:

Allowsanapplicationtoinjectuserevents(keys,touch,trackball)intotheeventstreamanddeliverthemtoANYwindow.

允许一个应用程序向事件流(事件队列)注入用户事件(keystouchtarckball),并且将其传递给窗口。

android.permission.INSTALL_LOCATION_PROVIDER:

AllowsanapplicationtoinstallalocatonproviderintthelocationManager.

允许应用程序程序安装一个位置服务到位置管理器。

androd.permission.INSTALL_PCAKAGES:

Allowsanapplicationtoinstallpackages.

允许一个应用程序安装packages。(用于版本升级的?)

android.permission.INTERNAL_SYSTEM_WINDOW:

Allowsanapplicationtoopenwindowsthatareforusebypartsofthesystemuserinterface.

允许一个应用程序打开系统用户界面中的窗口。

android.permission.INTERNET:

Allowsapplicationtoopennetworkdsockets.

允许应用程序打开网络套接字(sockets)。

android.permission.KILL_BACKGROUND_PROCESSES:

AllowsanapplicationtocallkillBackgroundProcesses(String).

允许应用程序调用killBackgroundProcesses(String)方法。

android.permission.MANAGE_ACCOUNTS:

AllowsanapplicationtomanagethelistofaccoutsintheAccountManager.

允许应用程序管理AccountManager中的账户列表。

android.permission.MANAGE_APP_TOKENS:

Allowsanapplicationtomanage(create,destroy,Z-order)applicationtokensinthewindowmanager.

允许一个应用程序管理(创建、销毁、Z-order)在窗口管理器中的应用程序图标。

android.permission.MASTER_CLEAR:

none.

没任何描述。

android.permisson.MODIFY_AUDIO_SETTINGS:

Allowsanapplicationtomodifyglobalaudiosettings.

允许一个应用程序更改全局音频设置。

android.permission.MODIFY_PHONE_STATE:

Allowsmodificationofthetelephonystate–poweron,mmi,etc.

允许修改电话(手机?)状态——上电,人机界面(mmi,ManMachineInterface)等。

android.permission.MOUNT_FORMAT_FILESYSTEMS:

Allowsformattingfilesysytemsforremovablestorage.

允许格式化移动存储设备。

android.permission.MOUNT_UNMOUNT_FILESYSYTEMS:
Allowsmountingandunmountingthefilesysytemsforremovablestorage.

允许加载或卸载移动存储设备。

android.permission.FERSISTENT_ACTIVITY:
Allowsanapplicationtomakeitsactivitiespersistent.

允许一个应程序设置其activities具有持久性(persistentactivities是什么样的activites?)。

android.permission.PROCESS_OUTGOING_CALLS:

Allowsanapplicationtomonitor,modify,orabortoutgoingcalls.

允许应用程序监视、修改、忽略拨出的电话(拨号)

android.permission.READ_CALENDAR:

Allowsanapplicationtoreadtheuser’scalendardata.

允许一个应用程序读取用户日历数据。

android.permission.READ_CONTACTS:

Allowsanapllicationtoreadtheuser’scontactsdata.

允许一个应用程序读取用户联系人列表。

android.permission.READ_FRAME_BUFFER:

Allowsanapplicationtotakescreenshotsandmoregenerallygetaccesstotheframebufferdata.

允许一个应用程序通过访问帧缓冲区(一般一屏就是一帧)获取屏幕截图等帧数据。

android.permission.READ_HISTORY_BOOKMARKS:

Allowsanapplicationtoread(butnotwrite)theuser’sbrowsinghistoryandbookmarks.

允许一个应用程序读取浏览器的历史记录和书签。

android.permission.READ_INPUT_STATE:

Allowsanapplicationtoretrievethecurrentstateofkeysandswitches.

允许一个应用程序获取当前keysswitches的状态(keysswitchs都是输入设备)。

android.permission.READ_LOGS:

Allowsanapplicationtoreadthelow-levelsystemlogfiles.

允许一个应用程序读取底层系统的log文件。

android.permission.READ_OWNER_DATA:

Allowsanapplicationtoreadtheowner’sdata.

允许一个应用程序读取所有者的数据。(手机的owner?)

android.permission.READ_PHONE_STATE:

Allowsreadonlyaccesstophonestate.

允许读取(不可写)手机状态。

android.permission.READ_SMS:

AllowsanapplicationtoreadSMSmessages.

允许一个应用程序读取手机短消息。

android.permission.READ_SYNC_SETTING:

Allowsapplicationstoreadthesyncsetting.

允许应用程序读取同步设置

android.permission.READ_SYNC_STATS:

Allowsapplicationstoreadsyncstats.

允许一个应用程序读取同步状态。

android.permission.REBOOT:

Requiredtobeabletorebootthedevice.

重启设备必须具有的权限。

android.permission.RECEIVE_BOOT_COMPLETED:

AllowsanapplicationtoreceivetheACTION_BOOT_COMPLETEDthatisboradcastafterthesysytemfinishesbooting.

允许应用程序获取系统完全启动之后的ACTION_BOOT_COMPLETED广播。

android.permission.RECEIVE_MMS:

AllowsanapplicationtomonitorincomingMMSmessages,torecordorperformprocessingonthem.

允许一个应用程序监控收到的彩信(MMS),记录或处理之。

android.permission.RECEIVE_SMS:

AllowsanapplicationtomonitorincomingSMSmessages,torecordorperformprocessingonthem.

允许一个应用程序监控收到的短信(SMS),记录或处理之。

android.permission.RECEIVE_WAP_PUSH:

AllowsanapplicationtomonitorincomingWAPpushmessages.

允许一个应用程序监测接受的WAP-PSUH消息。

android.permission.RECORD_AUDIO:
Allowsanapplicationtorecordaudio.

允许一个应用程序录音。

android.permission.REORERD_TASKS:

AllowsanapplicationtochangetheZ-orderoftasks.

允许一个应用程序改变任务的Z-order(类似于优先级?)

android.permission.RESTART_PACKAGES:

Thisconstantisdeprecated.TherestartPackage(String)APIisnolongersupported.

这个常量已不再使用,restartPackage这个API函数不再有效。

android.permission.SEND_SMS:
AllowsanapplicationtosendSMSmessages.

允许应用程序发送短消息(SMS)。

android.permission.SET_ACTIVITY_WATHCER:

Allowsanapplicationtowatchandcontrolhowactivitiesarestartedgloballyinsystem.

允许一个应用程序在全局系统中监控activities是如何被启动的。

android.permission.SET_ALWAYS_FINISH:

Allowsanapplicationtocontrolwhetheractivitiesareimmediatelyfinishedwhenputinthebackground.

允许应用程序无论activies是否刚刚结束,都将应用程序置于后台运行。(强制结束activies,置应用程序于后台运行?)

android.permission.SET_ANIMATION_SCALE:

Modifytheglobalanimationscalingfactor.

修改全局动画缩放比例。

android.permission.SET_DEBUG_APP:

Configureanapplicationfordebugging.

为调试配置一个应用程序。

android.permission.SET_ORIENTATION:

Allowslow-levelaccesstosettingtheorientation(actuallyrotation)ofthescreen.

允许设置屏幕方向(实际上就是旋转屏幕)。

android.permission.SET_PREFERRED_APPLICATIONS:

Thisconstantisdeprecated,Nolongeruseful,seeaddPackageToPreferred(String)fordetails.

这个常量已经无效了。

android.permission.SET_PROCESS_LIMIT:

Allowsapplicationtosetthemaximumnumberof(notneeded)applicationprocessesthatcanberuning.

允许应用程序设置最大可用进程数(不是必须的)。

android.permission.SET_TIME:

Allowsapplicationstosetthesystemtime.

允许应用程序设置系统时间。

android.permission.SET_TIME_ZONE:

Allowsapplicationstosetthesystemtimezone.

允许应用程序设置系统时区。

android.permission.SET_WALLPAPER:

Allowsapplicationstosetthewallpaper.

允许应用程序设置桌面。

android.permission.SET_WALLPAPER_HINTS:
Allowsapplicationtosetwallpaperhints.

允许应用程序设置桌面提示。(wallpaperhints是什么东东?)

android.permission.SINGAL_PERSISTENT_PROCESSES:

Allowsanapplicationtorequestthatasignalbesenttoallpersistentprocesses.

允许应用程序请求一个发送给所有持续进程的信号(signal)。(persistentprocesses是什么样的进程?)

android.permission.STATUS_BAR:

Allowsanapplicationtoopen,close,ordisablethestatusbaranditsicons.

允许一个应用程序打开、关闭、禁用状态栏和状态栏图标。

android.permission.SUBSCRIBED_FEEDS_READ:

AllowsanapplicationtoallowaccessthesubscribedfeedsContentProvider.

允许一个应用程序访问订阅RSSfeedsContentProvider

android.permission.SUBSRIBED_FEEDS_WRITE:

None.

没有任何描述。

android.permission.SYSYTEM_ALERT_WINDOW:
AllowsanapplicationtoopenwindowsusingthetypeTYPE_SYSTEM_ALERT,showontopofallotherapplications.

允许应用程序打开一个TYPE_SYSTEM_ALERT类型的系统警告(提示)窗口,并将其置于顶层显示。

android.permission.UPDATE_DEVICE_STATS:

Allowsanapplicationtoupdatedevicestatistics.

允许应用程序更新设备统计信息。

android.permission.USE_CREDENTIALS:

AllowsanapplicationtorequestauthtokensfromtheAccountManager.

允许一个应用程序向AccountManager申请授权标记。

android.permission.VIBRATE:

Allowsaccesstothevibrator.

允许访问振动器。

android.permission.WAKE_LOCK:

AllowsusingPowerManagerWakeLockstokeepprocessorfromsleepingorscreenfromdimming.

允许使用PowerManagerWakeLocks,避免处理器进入休眠,或屏幕变暗。

android.permission.WRITE_APN_SETTINGS:

Allowsapplicationstowritetheapnsettings.

允许应用程序设置APN

说明:APNAcessPointName)即接入点名称,用来标识GPRS的业务种类,目前分为两大类:CMWAP(通过GPRS访问WAP业务)、CMNET(除了WAP以外的服务目前都是CMNET,比如连接因特网等)。

android.permission.WRITE_CALENDAR:

Allowsanapplicationtowrite(butnotread)theuser’scalendardata.

允许应用程序只写用户日历数据。

android.permission.WRITE_CONTACTS:

Allowsanapplicationtowrite(butnotread)theuser’scontactsdata.

允许应用程序只写用户联系人数据。

android.permission.WRITE_EXTERNAL_STORAGE:

Allowsanapplicationtowritetoexternalstorage.

允许应用程序写数据到外部存储设备(主要是SD)

android.permission.WRITE_GSERVICES:

AllowsanapplicationtomodifytheGoogleservicemap.

允许应用程序修改google地图服务。

android.permission.WRITE_HISTORY_BOOKMARKS:

Allowsanapplicationtowrite(butnotread)theuser’sbrowsinghistoryandbookmarks.

允许一个应用程序写数据到用户浏览器历史记录和书签。

android.permission.WRITE_OWNER_DATA:

Allowsanapplicationtowrite(butnotread)theowner’sdata.

允许一个应用程序写入(填入)所有者(手机所有者?)的信息。

android.permission.WRITE_SECURE_SETTINGS:

Allowsanapplicationtoreadorwritethesecuresystemsettings.

允许一个应用程序读写系统安全设置。

android.permission.WRITE_SETTINGS:

Allowsanapplicationtoreadorwritethesystemsetting.

允许一个应用程序读写系统设置。

android.permission.WRITE_SMS:

AllowsanapplicationtowriteSMSmessages.

允许一个应用程书写短消息。

android.permisson.WRITE_SYNC_SETTING:

Allowsapplicationstowritethesyncsetting.

允许应用程序更改同步设置。

感谢:http://disanji.net/2011/03/18/android-app-permission/

更多相关文章

  1. 获取Android设备的方向
  2. 5.17学习内容 android判断软键盘状态、系统键盘监控、生成中间lo
  3. Android 打开相机、相册获取图片文件,支持Android 9.0系统
  4. android中调用系统功能 来显示本地相册图片 拍照 视频 音频功能
  5. android的设备永不休眠(增加 Settings-->Dispaly-->-->screenout-
  6. 关于Android LOG系统
  7. 简单的通过request判断客户端设备类型
  8. [置顶] android调用系统相机拍照并保存在本地
  9. Android调用系统下载服务下载文件

随机推荐

  1. Glide框架V3版本和V4版本区别
  2. java泛型操作复习,以及讲解在android中使
  3. Android含文档server结束(client UI接口异
  4. Android(安卓)后台任务(四)Loader
  5. ArcGIS for Android(安卓)在Eclipse上的
  6. Android(安卓)Studio添加字体解决方案
  7. Android(安卓)1.5 在eclipse中出现:Intern
  8. Android(安卓)Studio 入门
  9. Android开发,用C#!
  10. Android定时广播和定时服务两种实现方式