In this paper, we study a utility based flow control problem for a communication network. In most previous works on utility based flow control, the utility function of each user, which represents its satisfaction to the allocated data rate, is assumed to be fixed. This implies that the degree of the rate requirement of each user is assumed to be fixed over the entire duration of its session. However, in the communication network, many services are variable rate services, i.e., the degree of their rate requirement varies over time. Hence, in this paper, we allow the degree of the rate requirement of each user to change over time and model it by using a stochastic utility function that varies stochastically according to the variation of the degree of its rate requirement. We formulate a stochastic optimization problem with stochastic utility functions that aims at maximizing the average network utility while satisfying the constraint on the link capacity. By solving the stochastic optimization problem, we develop a distributed flow control algorithm that converges to the optimal rate allocation.