private void authorizeDropPartition(PreDropPartitionEvent context)
      throws InvalidOperationException, MetaException {
    try {
      for (HiveMetastoreAuthorizationProvider authorizer : tAuthorizers.get()) {
        if (authorizer instanceof HiveMultiPartitionAuthorizationProviderBase) {
          // Authorize all dropped-partitions in one shot.
          authorizeDropMultiPartition((HiveMultiPartitionAuthorizationProviderBase)authorizer, context);
        }
        else {
          // Authorize individually.
          TableWrapper table = new TableWrapper(context.getTable());
          Iterator<Partition> partitionIterator = context.getPartitionIterator();
          while (partitionIterator.hasNext()) {
            authorizer.authorize(
                new PartitionWrapper(table, partitionIterator.next()),
                HiveOperation.ALTERTABLE_DROPPARTS.getInputRequiredPrivileges(),
                HiveOperation.ALTERTABLE_DROPPARTS.getOutputRequiredPrivileges()
            );
          }
        }
      }
    } catch (AuthorizationException e) {
      throw invalidOperationException(e);
    } catch (HiveException e) {
      throw metaException(e);
    }
  }
AuthorizationPreEventListener : A MetaStorePreEventListener that
performs authorization/authentication checks on the metastore-side.

Note that this can only perform authorization checks on defined
metastore PreEventContexts, such as the adding/dropping and altering
of databases, tables and partitions.
ql/src/java/org/apache/hadoop/hive/ql/security/authorization/AuthorizationPreEventListener.java