Did you mean JOSM as in Java OpenStreetMap Editor?
You can use the software for whatever purpose you like. It’s free software. Openstreetmap data can be reused for commercial purposes as well, as long as a mention is made that it came from the Openstreetmap contributors.
You cannot, however, include the source code of JOSM in another project that’s not released under the same license once again. So you cannot reuse the source code in a commercial project.