Anonymous wireless networks use covert relays to prevent unauthorized entities from determining communicating parties through traffic timing analysis. In a multipath anonymous network, the choice of which relay nodes should be covert, as well as the route selection by the network nodes, affect both the anonymity and network performance. Although assigning relays as covert and selecting routes composed of covert relays can provide higher anonymity, the selection of these two parameters will increase the packet dropping rate of the network. In this paper, we introduce an analytical framework for joint relay assignment and route selection in multi-path anonymous wireless networks. The main contributions of this work are two-fold. First, we show that joint relay assignment and route selection can be formulated as a convex optimization problem which guarantees global optimum solution. Second, as special cases of our formulation, we derive solutions for the problem of route selection to maximize anonymity when the relay configuration is given, as well as the problem of relay configuration for a given route selection.