配置基于 ApiKey 的鉴权对象

@return
329810
private ApiKey apiKey() {
        return new ApiKey(swaggerProperties().getAuthorization().getName(),
                swaggerProperties().getAuthorization().getKeyName(),
                ApiKeyVehicle.HEADER.getValue());
    }
68475
public HashMap<Integer, byte[]> getPreKeys() {
        if (preKeys == null) {
            preKeys = new HashMap<>();
            for (int id : preKeysB64.keySet()) {
                preKeys.put(id, Base64.decode(preKeysB64.get(id)));
            }
        }
        return this.preKeys;
    }
827804
byte[][] getFamilyKeys() {
		Charset c = Charset.forName(charset);

		byte[][] familyKeys = new byte[this.familyMap.size()][];
		int i = 0;
		for (String name : this.familyMap.keySet()) {
			familyKeys[i++] = name.getBytes(c);
		}
		return familyKeys;
	}
658705
public final SecretKey generateKey() {
        if (serviceIterator == null) {
            return spi.engineGenerateKey();
        }
        RuntimeException failure = null;
        KeyGeneratorSpi mySpi = spi;
        do {
            try {
                return mySpi.engineGenerateKey();
            } catch (RuntimeException e) {
                if (failure == null) {
                    failure = e;
                }
                mySpi = nextSpi(mySpi, true);
            }
        } while (mySpi != null);
        throw failure;
   }
1270718
public static String accessToken(String key) {
		if (isKeyParam(key)) {
			String[] keys = key.split(KEY_JOIN);
			if (keys.length == 2) {
				return apiHandler.accessToken(keys[0], keys[1]);
			} else if (keys.length == 1) {
				return apiHandler.accessToken(keys[0]);
			}
		}
		return key;
	}
171461
public function api_keys($apiKey = null)
    {
        $api_keys = self::all_api_keys();
        $my_api_keys = null;

        if ($api_keys->id == $this->id) {
            $my_api_keys = $api_keys->keys;
        }
        if (is_null($my_api_keys)) {
            foreach($api_keys->children as $children_keys) {
                if ($children_keys->id == $this->id) {
                    $my_api_keys = $children_keys->keys;
                }
            }
        }

        if (is_null($my_api_keys)) {
            return null;
        } else {
            $response = array();
            foreach($my_api_keys as $key) {
                $response[$key->mode] = $key->key;
            }
            return $response;
        }
    }
361318
public byte[] getPrivate() {
        keyNotNull(pair.getPrivate());
        Key key = pair.getPrivate();
        return getKeyBytes(key);
    }
772325
public byte[] getKeySetToByteArray() 
    {
        ByteArrayOutputStream baos = new ByteArrayOutputStream();
        DataOutputStream dos = new DataOutputStream(baos);
        
        char[] buffer = new char[getMaxFieldLenth()];
        
        try
        {
            for ( String s : keys )
            {
                Arrays.fill(buffer, (char)0);
                System.arraycopy( s.toCharArray(), 0, buffer, 0, s.length() );
                dos.writeBytes( new String(buffer) );
            }
        }
        catch  (IOException e)
        {
            System.err.println("Could not write Structure key set to byte array: " + e );
            return new byte[0];
        }
        return baos.toByteArray();
        
    }
1168961
public String[] getKeyStoreAliases() {
        Set<String> set = keyStoreMap.keySet();
        return set.toArray(new String[set.size()]);
    }
1315412
private String getApiIndex(Api api) {
        return getApiIndex(api.getOrganizationId(), api.getApiId(), api.getVersion());
    }
1294906
@GET
    @Produces(MediaType.APPLICATION_JSON)
    @RequiresPermissions(I18nPermissions.KEY_READ)
    public KeyRepresentation getKey() {
        KeyRepresentation keyRepresentation = keyFinder.findKeyWithName(keyName);
        if (keyRepresentation == null) {
            throw new NotFoundException(String.format(KEY_NOT_FOUND, keyName));
        }
        return keyRepresentation;
    }
452902
public APIState getAPIState() {
		APIStateRequest request = new APIStateRequest();
		APIStateResponse response = resolveApitraryClient().send(request);

		APIState apiState = null;
		if (HttpStatus.OK.ordinal() == response.getStatusCode()) {
			String result = response.getResult();

			ObjectMapper objectMapper = new ObjectMapper();
			try {
				apiState = objectMapper.readValue(result, APIState.class);
			} catch (Exception e) {
				throw new MappingException(e);
			}
		} else {
			throw new CommunicationErrorException(HttpStatus.getStatus(response.getStatusCode()));
		}
		return apiState;
	}
424443
@Override
  public List<String> listKeys() {
    lock.lock();
    try {
      List<String> keys = new ArrayList<>(this.items.size());
      for (Map.Entry<String, ApiType> entry : this.items.entrySet()) {
        keys.add(entry.getKey());
      }
      return keys;
    } finally {
      lock.unlock();
    }
  }
837948
@Override
    public byte[] getKey() {
        StringBuilder sb = new StringBuilder(128);
        sb.append(clusterName).append(MetricUtils.AT).append(topologyId).append(MetricUtils.AT)
                .append(taskId).append(MetricUtils.AT);
        if (start != null) {
            sb.append(start.getTime());
        } else {
            sb.append(end.getTime());
        }
        return sb.toString().getBytes();
    }
797789
public java.util.List<KeyListEntry> getKeys() {
        if (keys == null) {
            keys = new com.ibm.cloud.objectstorage.internal.SdkInternalList<KeyListEntry>();
        }
        return keys;
    }
1250343
protected Collection<String> getKeys() {
		Collection<String> result = Collections.emptySet();
		if (_moduleBuilds != null) {
			result = Collections.unmodifiableCollection(_moduleBuilds.keySet());
		}
		return result;
	}
1361338
@Override
  public ApiType getByKey(String key) {
    lock.lock();
    try {
      return this.items.get(key);
    } finally {
      lock.unlock();
    }
  }