Let $G=(V, E)$ be a simple connected graph. A nonempty set $S\subseteq V$ is a secure set if every attac(K) on $S$ is defendable. In this paper, $(K)$-secure sets are introduced as a generalization of secure sets. For any integer $(K)\geq 0$, a nonempty subset $S$ of $V$ is a $(K)$-secure set if, for each attac(K) on $S$, there is a defense of $S$ such that for every $v\in S$, the defending set of $v$ contains at least $(K)$ more elements than that of the attac(K)ing set of $v$, whenever the vertex $v$ has neighbors outside $S$. The cardinality of a minimum $(K)$-secure set in $G$ is the $(K)$-security number of $G$. Some properties of $(K)$-secure sets are discussed and a characterization of $(K)$-secure sets is obtained. Also, 1-security numbers of certain classes of graphs are determined.