Create a new CredentialListInstance

        :param unicode friendly_name: Human readable descriptive text

        :returns: Newly created CredentialListInstance
        :rtype: twilio.rest.api.v2010.account.sip.credential_list.CredentialListInstance
332058
def create(self, friendly_name):
        
        data = values.of({'FriendlyName': friendly_name, })

        payload = self._version.create(
            'POST',
            self._uri,
            data=data,
        )

        return CredentialListInstance(self._version, payload, account_sid=self._solution['account_sid'], )
23774
def MakeSuiteFromList(t, name=''):
    
    hist = MakeHistFromList(t)
    d = hist.GetDict()
    return MakeSuiteFromDict(d)
409587
def add_domain_name_list(list_name):
    '''
    

    '''
    payload = {"jsonrpc": "2.0",
               "id": "ID0",
               "method": "add_policy_domain_names_list",
               "params": [{"list_name": list_name}]}

    response = __proxy__['bluecoat_sslv.call'](payload, True)

    return _validate_change_result(response)
411732
def create_waf(self, name, waf_type):
        
        params = {
            'name': name,
            'type': waf_type
        }
        return self._request('POST', 'rest/wafs/new', params)
731260
def list_credentials_by_name(type_name):
  
  accounts = get_all_external_accounts(api, type_name)
  account_names = [account.name for account in accounts]
  print ("List of credential names for '{0}': [{1}]".format(
    type_name, COMMA_WITH_SPACE.join(map(str, account_names))))
956000
public Client setFriendlyName(int profileId, String clientUUID, String friendlyName) throws Exception {
        // first see if this friendlyName is already in use
        Client client = this.findClientFromFriendlyName(profileId, friendlyName);
        if (client != null && !client.getUUID().equals(clientUUID)) {
            throw new Exception("Friendly name already in use");
        }

        PreparedStatement statement = null;
        int rowsAffected = 0;

        try (Connection sqlConnection = sqlService.getConnection()) {
            statement = sqlConnection.prepareStatement(
                "UPDATE " + Constants.DB_TABLE_CLIENT +
                    " SET " + Constants.CLIENT_FRIENDLY_NAME + " = ?" +
                    " WHERE " + Constants.CLIENT_CLIENT_UUID + " = ?" +
                    " AND " + Constants.GENERIC_PROFILE_ID + " = ?"
            );
            statement.setString(1, friendlyName);
            statement.setString(2, clientUUID);
            statement.setInt(3, profileId);

            rowsAffected = statement.executeUpdate();
        } catch (Exception e) {

        } finally {
            try {
                if (statement != null) {
                    statement.close();
                }
            } catch (Exception e) {
            }
        }

        if (rowsAffected == 0) {
            return null;
        }
        return this.findClient(clientUUID, profileId);
    }
603721
def credentials(self):
        
        if self._credentials is None:
            self._credentials = CredentialList(
                self._version,
                account_sid=self._solution['account_sid'],
                credential_list_sid=self._solution['sid'],
            )
        return self._credentials
984556
def credential_lists(self):
        
        if self._credential_lists is None:
            self._credential_lists = CredentialListList(
                self._version,
                account_sid=self._solution['account_sid'],
            )
        return self._credential_lists
1214526
def add_credential(self, url, username, password):
        
        cur = self.conn.cursor()

        cur.execute("SELECT * FROM credentials WHERE LOWER(username)=LOWER(?) AND password=?", [url, username, password])
        results = cur.fetchall()

        if not len(results):
            cur.execute("INSERT INTO credentials (username, password) VALUES (?,?)", [username, password] )

        cur.close()
695444
def _generate_presence_token(self, channel_name):
        
        subject = "{}:{}:{}".format(self.connection.socket_id, channel_name, json.dumps(self.user_data))
        h = hmac.new(self.secret_as_bytes, subject.encode('utf-8'), hashlib.sha256)
        auth_key = "{}:{}".format(self.key, h.hexdigest())

        return auth_key
1271170
def generate_namelist_file(self, rapid_namelist_file):
        
        log("Generating RAPID namelist file ...",
            "INFO")
        try:
            os.remove(rapid_namelist_file)
        except OSError:
            pass

        with open(rapid_namelist_file, 'w') as new_file:
            new_file.write('&NL_namelist\n')
            for attr, value in sorted(list(self.__dict__.items())):
                if not attr.startswith('_'):
                    if attr.startswith('BS'):
                        new_file.write("{0} = .{1}.\n"
                                       .format(attr, str(value).lower()))
                    elif isinstance(value, int):
                        new_file.write("%s = %s\n" % (attr, value))
                    else:
                        if value:
                            if os.name == "nt":
                                # if windows generate file with cygpath
                                value = self._get_cygwin_path(value)
                            new_file.write("%s = \'%s\'\n" % (attr, value))
            new_file.write("/\n")
1011740
def allow_client_incoming(self, client_name):
        
        self.client_name = client_name
        self.capabilities['incoming'] = ScopeURI('client', 'incoming', {'clientName': client_name})
123313
def fill_auth_list(self, auth_provider, name, groups, auth_list=None, permissive=None):
        '''
        
        '''
        if auth_list is None:
            auth_list = []
        if permissive is None:
            permissive = self.opts.get('permissive_acl')
        name_matched = False
        for match in auth_provider:
            if match == '*' and not permissive:
                continue
            if match.endswith('%'):
                if match.rstrip('%') in groups:
                    auth_list.extend(auth_provider[match])
            else:
                if salt.utils.stringutils.expr_match(match, name):
                    name_matched = True
                    auth_list.extend(auth_provider[match])
        if not permissive and not name_matched and '*' in auth_provider:
            auth_list.extend(auth_provider['*'])
        return auth_list
4520
def get_auth_instance(credentials, auth_type):
    
    model = AUTH_TYPE_MAP[auth_type]
    if model is None:
        return None
    username = credentials.username
    if auth_type == NTLM and credentials.type == credentials.EMAIL:
        username = '\\' + username
    if auth_type == GSSAPI:
        # Kerberos auth relies on credentials supplied via a ticket available externally to this library
        return model()
    return model(username=username, password=credentials.password)
292061
def friendly_fqcn(cls_name):
    
    if isinstance(cls_name, type):
        cls_name = fqcn(cls_name)

    return cls_name.rsplit(".", 1)[-1]
948979
def create_user(self, name, password, database_names, host=None):
        
        if not isinstance(database_names, (list, tuple)):
            database_names = [database_names]
        # The API only accepts names, not DB objects
        database_names = [db if isinstance(db, six.string_types) else db.name
                for db in database_names]
        self._user_manager.create(name=name, password=password,
                database_names=database_names, host=host, return_none=True)
        # Since the API doesn't return the info for creating the user object,
        # we have to do it manually.
        return self._user_manager.find(name=name)
703709
def create_iplist_with_data(name, iplist):
    
    iplist = IPList.create(name=name, iplist=iplist)
    return iplist