Some people will go to extended lengths to do this... They'll boil water and pour it into sanitized containers (something that won't crack with heat shock or melt) and then freeze it, and when they're reading to add the wort then they'll put the ice into their fermenter and pour it on top of the ice. When I was doing partial boils I would just pour near-freezing water into my fermenter and add it that way.
Using ice to directly cool the wort works just fine...IF the ice is clean, pure and nasty-bacteria-free. I have used store-bought ice...and the company that supplies it is almost anal-retentive about cleanliness and purity. So, depending on the supplier of the ice, it may be fine, or it may not be such a good idea.
I mostly use partial mash to brew. I may do things a little different, but I brew on a stove. Therefore, I cannot do a full boil. I can do 3-4 gallon boil. When done, I use a cold water bath to get my temp down to around 100-120F. Then I use a two liter bottle of water that has been sanitized and froze prior to brew day. I cut that bottle up with a sanitized knife and put it in my wort and it takes it down that final 30 degrees or so. Works like a charm and I have not had any problems yet.
I used two bags of store-bought ice for my first-ever brew last night, and am a bit worried. I sanitized the outside of one bag, but I think I forgot to sanitize the second one as the hour was getting later. How will I know if I've introduced some kind of contaminant? Dump now or wait and see? Thanks!
When I brewed extract and didn't have a wort chiller, I would rinse and sanitize the 1/2 gallon milk jugs the LME came in. Then I would fill them 3/4 full and freeze them. They are great for keeping a cooler full of homebrew cold while at the lake for a day or even two. If I didn't use them for cooling the finished product, I would sanitize them out of the freezer and cut the jug in half. The 3/4 gallon of ice would go right in the fermentor. 2-3 of those would cool down 3.5 to 4 gallons of boiling wort in no time.
When I did extract I used to use bagged ice to cool it. I never had an infection from it, but it is still a gamble. You should be fine, but there is always a chance. Beer is rather hearty and the yeast should take over if you pitched enough. RDWHAB until your batch is ready. Then HAHB