Got a picture?
There's no great way to install a railing that's just attached to the surface of a slab.
You can attach it but it's going to move.
Some options are to go with a powder coated railing and core drill some holes and you can epoxy them in place.
Or set the 4 X 4 beside the steps set in concrete.